I have extended the DatabaseServerLoginModule to allow for limiting the number of login attempts and locking the username when the limit is exceeded before a successful login. My class seems to work well. I am interested in passing a message back to the error jsp that the username has been locked as opposed to the usual condition of username/password mismatch. Is this possible, I currently do not see any way to do it. In my class I throw a FailedLoginException() with the message that the username is locked, when this condition occurs.