

Harika! Yazıyı İngilizce olarak, teknik terimlere sadık kalarak ve akıcı bir blog formatında senin için hazırladım:
During web penetration testing or security assessments, the very first thing we do when touching a target system is figure out which web server is running underneath and check whether default, out-of-the-box configurations were left exposed.
Whether it is Apache, Nginx, Node.js, or Python's HTTP server, developers often leave default settings untouched for the sake of deployment ease. In this post, we will explore how to fingerprint a web server and spot common misconfigurations using simple curl commands.
Instead of downloading the entire page content when hitting a server, fetching only the HTTP response headers is fast and provides immediate clues about the server software.
Using the -I (or --head) parameter, we can request just the response headers:
Bash
curl -sI http://<target-ip>:<port>/
What are we looking for?
If directory indexing (autoindex or Apache module configurations) is left enabled on a server, sensitive files (.env, backups, notes) can be accessed directly via browser or curl.
For instance, to list a /files/ directory:
Bash
curl -s http://<target-ip>:<port>/files/
If we suspect a backup or configuration file exists, we can download it directly:
Bash
curl -s http://<target-ip>:<port>/files/deploy-notes.txt
On Python-based built-in servers, which lack any access controls, even hidden dotfiles in the root directory can be exposed:
Bash
curl -s http://<target-ip>:<port>/.env
Servers often host specific administrative or debugging endpoints intended for internal performance monitoring. These should always be restricted from the public.
curl -s http://<target-ip>/server-status
curl -s http://<target-ip>:8080/nginx_status
curl -s http://<target-ip>:3000/api/routes
curl -s http://<target-ip>:3000/api/debug/env
Modern web applications require security headers to protect against client-side attacks (such as Clickjacking and XSS). We can quickly audit all open ports in a loop to see if these headers are missing:
Bash
for port in 80 8000 3000 8080; do
echo "=== Port $port ===";
curl -sI http://<target-ip>:$port/ | grep -iE "x-frame-options|x-content-type|content-security-policy|strict-transport|referrer-policy" || echo "(no security headers found)";
done
If the output returns (no security headers found), the target server completely lacks client-side defense headers.
While automated scanners like Nikto are invaluable tools, performing manual analysis with command-line utilities like curl lets you understand server behavior firsthand and catch details that automation might gloss over.
Remember: insecure default configurations are rarely sheer negligence—they are simply unreviewed defaults. Always complete your hardening checklist before pushing any web server to production!