Question Detail

How to hide Apache Version and OS Identity from Errors in xampp localhost ?

6 years ago Views 3502 Visit Post Reply

How to hide this Apache info from error page. Xampp localhost

Apache/2.4.27(Win32) OpenSSL/1.0.21 PHP/7.1.9 Server at domain.com Port 8080


Thread Reply

goldy

- 6 years ago

You can easily hide Apche (httpd) version number and other information. There are two config directives that controls Apache version. The ServerSignature directive adds a line containing the Apache HTTP Server server version and the ServerName to any server-generated documents, such as error messages sent back to clients. ServerSignature is set to on by default. The ServerTokens directive controls whether Server response header field which is sent back to clients includes a description of the generic OS-type of the server as well as information about compiled-in modules. By setting this to Prod you only displays back Apache as server name and no version number displayed back.

Open your httpd.conf file using text editor such as vi:
vi httpd.conf

Append/modify config directive as follows:
ServerSignature Off
ServerTokens Prod

Save and close the file. Restart Apache web server:
# /etc/init.d/httpd restart

Anonymous

- 6 years ago

Open your httpd.conf file using text editor such as vi:
vi httpd.conf

Append/modify config directive as follows:
ServerSignature Off
ServerTokens Prod

Save and close the file. Restart Apache web server:
# /etc/init.d/httpd restart