Submit a ticketCall us

Get a crash course on Network Monitoring delivered right to your inbox
This free 7-day email course provides a primer to the philosophy, theory, and fundamental concepts involved in IT monitoring. Lessons will explain not only how to perform various monitoring tasks, but why and when you should use them. Sign up now.

Home > Success Center > Web Help Desk (WHD) > Apache Tomcat version number displays in error messages

Apache Tomcat version number displays in error messages

Updated June 14, 2017

Overview

When a user accesses a web page that does not exist on the Apache™ Tomcat™ server (as shown below), the Tomcat version number displays at the bottom of the error message. This issue may cause a security risk. 

Environment

  • All Apache Tomcat versions
  • All Web Help Desk versions

Cause 

Apache Tomcat does not include a method to change the error message. 

Workaround

Create a ServerInfo.properties file in the Tomcat directory to override the Tomcat version number in the error message. 

  1. Log in to the Web Help Desk server as an administrator.
  2. Navigate to the Web Help Desk home directory.
    • Apple® OS X®: /Library/WebHelpDesk
    • Microsoft Windows®:  \Program Files\WebHelpDesk
    • Linux: /usr/local/webhelpdesk
  3. In the WebHelpDesk directory, navigate to \bin\tomcat\lib
  4. In the \lib directory, back up the catalina.jar file to a separate directory.
  5. Modify the ServerInfo.properties file.
    1. Unzip the catalina.jar file using a compression utility (such as 7-ZIP).
    2. Locate and open the ServerInfo.properties file in a text editor (such as NotePad).
    3. Change the server.info and server.number properties to the following:
      server.info=
      server.number=0.0.0.0
    4. Save and close the file. 
    5. Using a compression utility, zip the files and rename the compressed file catalina.jar. Do not change the directory structure. 
  6. Navigate to the \bin\tomcat\conf directory.
  7. Back up the tomcat_server_template.xml file to a separate directory. 
  8. Modify the tomcat_server_template.xml file.  
    1. Open the tomcat_server_template.xml file in a text editor.
    2. Under Connector port, add the following parameter:
      server="APPSRV"
    3. Save and close the file. 
  9. Restart the Apache server.

When the error message reappears, the Apache Tomcat version number displays the parameter you added in the ServerInfo.properties file.

 

 

Last modified
14:19, 21 Jun 2017

Tags

Classifications

Public