2 Replies Latest reply on Sep 5, 2002 3:28 PM by poco

    Forward to various pages depending of login error type.

    poco

      Hi,
      I'd like to know if it is possible to forward to a couple of different pages (instead of the only <form-error-page>) depending on the type of error.

      I have extended the DatabaseServerLoginModule so that if the user tries to login 3 consecutives times without success, the account is locked and an EMail is sent to the system administrators. This works just fine, and with very little efforts.

      What I want now, is to inform the user that his account has been locked following those 3 login mismatch. Right now, all errors are fowarded to the login-error page which state that there was an error in the username-password combination.
      His there a way to bypass that?
      I also want to inform the user with a different error page if he tries to login and his account has already been locked... is it possible?? I manage to change the error page for when he is'nt part of the needed group
      with :
      <error-page>
      <error-code>403</error-code>
      /NotInGroup.jsp
      </error-page>

      in the web.xml file.

      Could I generate my own error codes and use the same technique to forward to the needed page? If so, an example would be nice.



      TIA!

        • 1. Re: Forward to various pages depending of login error type.
          poco

          well.. never mind the 403 thing.. it doe'nt work... must have been high or something.. I thought I've seen it worked.. but in fact, I get an error stating that this is not allowed... by the way, I use jboss+tomcat... still the question remains! ;)

          • 2. Re: Forward to various pages depending of login error type.
            poco

            lol.. I was'nt high... well.. not the time I've seen it worked at least! ;) Now it's working (always works better with the correct version of the file! ;) )...

            So, can I generate a specific error code that would give me the possibility to "specialize" the error page for the situation described earlier?

            thanks...