Security Issues – Banner Grabbing

Issue: Banner grabbing performed on web server via port 80, reveals apache version

banner grabbing

How to fix this issue?

Open the terminal and do the following as root:

Edit the apache configuration file.

vim /etc/httpd/conf/httpd.conf

In Mac OS X:

vim /etc/apache2/extra/httpd-default.conf

Find the ServerSignature directive.
In the vim editor, press [ESC] and type ServerSignature
This will locate where the said directive is.
By default, it is set to On. Now, change it to Off.

ServerSignature Off

Find the ServerTokens directive.
In the vim editor, press [ESC] and type ServerTokens
Set this to Prod

ServerTokens Prod

Save and exit from the editor by pressing [ESC] and typing wq.

Restart apache.

service httpd restart

or

/etc/init.d/httpd restart

In Mac OS:

apachectl -k restart

Having this two directives set makes sure no one can get your server version using the banner grabbing side of enumeration.

ServerSignature Off and ServerTokens Prod
Advertisements

One comment


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s