Apache Tomcat Version displayed

book

Article ID: 144042

calendar_today

Updated On:

Products

CA eHealth CA Spectrum

Issue/Introduction

Apache Tomcat Version information is shown when there is an error

 

Cause

By default in Server.xml (%SPECROOT%\tomcat\conf) 

showServerInfo is set to true under the Host tag hence it is showing that information.  

We need to make it false

Environment

Release : 10.4

Component : Spectrum Core / SpectroSERVER

Resolution

Please check the $SPECROOT\tomcat\conf\server.xml and make sure the showServerInfo is set to false under the Host tag.


      <Host name="localhost" appBase="webapps" unpackWARs="true" autoDeploy="false">

        <!-- Access log processes all requests for this virtual host.  By
             default, log files are created in the "logs" directory relative to
             $CATALINA_HOME.  If you wish, you can specify a different
             directory with the "directory" attribute.  Specify either a relative
             (to $CATALINA_HOME) or absolute path to the desired directory.
             This access log implementation is optimized for maximum performance,
             but is hardcoded to support only the "common" and "combined" patterns.
        -->
        <Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs" prefix="localhost_access_log." suffix=".txt" pattern="%l %u %t %r %s %b %D" resolveHosts="false" />
                 
        <Valve className="org.apache.catalina.valves.ErrorReportValve" showReport="true" showServerInfo="false" />
      </Host>

 

Now it will hide the Server Information



Attachments