I am using Tomcat 5.5.17 on Windows. I have a problem setting a 408 error-page in my web.xml on form based authentication.
I am using servlet spec defined authentication for my webapp: <login-config> <auth-method>FORM</auth-method> <realm-name>Authentication</realm-name> <form-login-config> <form-login-page>/login.jsp</form-login-page> <form-error-page>/error.jsp</form-error-page> </form-login-config> </login-config> Step 1) In a web browser, load the login.jsp page Step 2) Let the web browser sit on the login page for the period of time that would expire the users session (30 mins by default) Step 3) Click submit to send the authentication username/password. The result of this is, not surprisingly, an error. However, the error varies by web browser: Firefox 2 gives a browser error: "The connection was reset The connection to the server was reset while the page was loading. * The site could be temporarily unavailable or too busy. Try again in a few moments. * If you are unable to load any pages, check your computer's network connection. * If your computer or network is protected by a firewall or proxy, make sure that Firefox is permitted to access the Web." Internet Explorer 6 gives a tomcat error: "HTTP Status 408 - The time allowed for the login process has been exceeded. If you wish to continue you must either click back twice and re-click the link you requested or close and re-open your browser" So my first question: why is Firefox not displaying the 408 error? Next, I add an error-page element to my web.xml: <error-page> <error-code>408</error-code> <location>/408.html</location> </error-page> Then, follow the same 3 steps from above, and I would expect Firefox to display the same browser error, but IE should display my 408.html page. Firefox does display the same "The connection was reset" error, however, IE displays a new error: "The page is currently unavailable Due to current high demand, the page you are looking for cannot be delivered right now. -------------------------------------------------------------------------------- Please click the Refresh button, or try again later. HTTP Error 408 / 409 - Not acceptable / Resource conflict Internet Explorer" So my second question: why is the error-page 408.html that is defined in my web.xml, not being picked up and displayed to the browser? Thanks for reading all of this, -rg