^

Hide Server Version in Apache & Nginx

Article 62 in Linux

2020-11-19 12:29:03 from bugfish
Hide Server Version in Apache & Nginx
Linux / Security
Last Review on: 2021-08-02 08:39:59 | Hits: 174

NGINX

1. Go to the nginx configuration file:

nano /etc/nginx/nginx.conf

2. Uncomment this line:

server_tokens off;

3. Restart nginx

service nginx restart

APACHE2

1. Go to your apache2 configuration File:

nano /etc/apache2/apache2.conf (for Debian/Ubuntu)
nano /etc/httpd/conf/httpd.conf (Centos)

2. Modify the line ServerTokens and ServerSignature as below:

ServerTokens Prod
ServerSignature Off 

3. Restart Apache2 Service

service apache2 restart
I do not guarantee the reliability of the information given here, the code described on this page is executed at your own risk and in the event of damage or other unforeseeable consequences I am in no way responsible or liable.
Comment Section
Currently 0 Upvotes!
captcha image

System - 2021-01-01 19:30:38
We appreciate comments on our site!

Theme
2
This Website is using Session Cookies for Site Functionality and AWStats.