Re: Default error page generation logic in tomcat
Ok... I just figured out a work around for this to make work. I modified ServerInfo.properties from catalina.jar and re-jarred it and overrode the original catalina.jar. This seems to work. but, I am just curious whether this has any side effects? Earlier, I tried doing the same thing but, was not actually overriding catalina.jar proprely. Thanks, Raghu On Wed, Aug 13, 2008 at 1:02 PM, Caldarale, Charles R < [EMAIL PROTECTED]> wrote: > > From: Raghavendra Datt [mailto:[EMAIL PROTECTED] > > Subject: Re: Default error page generation logic in tomcat > > > > I have this tomcat running on linux and I don't find > > catalina.properties any where in the tomcat folders. > > A red flag just went up. Are you using a real Tomcat, or a 3rd-party > repackaged version? If the latter, it probably has scattered Tomcat files > all over the place, and will be prone to numerous errors and stability > issues. Suggest removing the Tomcat you have and downloading a real one > from http://tomcat.apache.org. > > - Chuck > > > THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY > MATERIAL and is thus for use only by the intended recipient. If you received > this in error, please contact the sender and delete the e-mail and its > attachments from all computers. > > - > To start a new topic, e-mail: users@tomcat.apache.org > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: Default error page generation logic in tomcat
Mark, Appreciate your response. I have this tomcat running on linux and I don't find catalina.properties any where in the tomcat folders. so, I tried unzipping this catalina.jar and changed the ServerInfo.Properties and zipped into catalina.jar. but, still I see that version info on an error. Do you know whether catalina.properties and catalina.policy ( which I could find in my linux) or same? Unzipping, modifying and zipping back - should this solve the problem? Thanks, Raghu On Wed, Aug 13, 2008 at 12:05 PM, Mark Thomas <[EMAIL PROTECTED]> wrote: > Raghavendra Datt wrote: > >> Hi Guys, >> I had a specific requirement related to tomcat error generation. When a >> default error page is generated like 404 error page, tomcat appends its >> version info at the bottom of the page. I don't want this version to be >> displayed on the error page. I am trying to understand which part of the >> tomcat code actually does this? >> > > It is the ErrorReportValve and it gets the information from > org.apache.catalina.util.ServerInfo > > You can over-ride this by: > > 1. extract org/apache/catalina/util/ServerInfo.properties from catalina.jar > and put that file in > ${CATALINA_HOME}/classes/org/apache/catalina/util/ServerInfo.properties > > 2. Edit ${CATALINA_HOME}/conf/catalina.properties and change > common.loader=${catalina.home}/lib,${catalina.home}/lib/*.jar > to > > common.loader=${catalina.home}/classes,${catalina.home}/lib,${catalina.home}/lib/*.jar > > Any values you put in > ${CATALINA_HOME}/classes/org/apache/catalina/util/ServerInfo.properties will > be used when reporting server name, version etc. > > HTH, > > Mark > > > > - > To start a new topic, e-mail: users@tomcat.apache.org > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Default error page generation logic in tomcat
Hi Guys, I had a specific requirement related to tomcat error generation. When a default error page is generated like 404 error page, tomcat appends its version info at the bottom of the page. I don't want this version to be displayed on the error page. I am trying to understand which part of the tomcat code actually does this? Any response will be appreciated. Thanks, Raghu