Why You Should Hide Your Server Version
Server version headers tell attackers exactly which vulnerabilities to target.
When a web server sends its version in the Server header, it's handing attackers a roadmap.
The problem
If your server responds with Server: Apache/2.4.41, an attacker can immediately look up every known CVE for Apache 2.4.41 and start probing.
Common offenders
- Apache:
Server: Apache/2.4.41 (Ubuntu) - Nginx:
Server: nginx/1.18.0 - PHP:
X-Powered-By: PHP/7.4.3 - ASP.NET:
X-Powered-By: ASP.NET
How to disable
Apache: ServerTokens Prod and ServerSignature Off
Nginx: server_tokens off;
PHP: expose_php = Off in php.ini