Tomcat modifies banner information

Source: Internet
Author: User
Tags constant tomcat
The server information is given when the HTTP server responds to the request, for example:

server:apache-coyote/1.1

This banner gives the intruder a certain indication. For security reasons, this information needs to be changed in order to play a certain role in the confusion.

Tomcat 6 Copies the entire LIB package, creates a new project, modifies

Tomcat-coyote.jar\org\apache\coyote\ajp\constants.class and Http11\constants.class. Change the server to the string you want.

Save, replace the original file in Tomcat-http.jar with this modified Constant.class (under Windows, drag the modified Constant.class directly to the Constant.class location in the WinRAR window Can).

When you are done, you can test:

Telnet

get/http/1.1

Results:

...

Server:unknown haha! vx.x
Transfer-encoding:chunked

...

In this way, it is not easy for an attacker to get the type/version information of the HTTP server.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.