We\'re using spring security 3.0.5, Java 1.6 and Tomcat 6.0.32. In our .xml config file we\'ve got:
I did it this way:
Created a class that extends SimpleUrlAuthenticationFailureHandler
SimpleUrlAuthenticationFailureHandler
Overrid the onAuthenticationFailure method, which receives an HttpServletRequest as a parameter.
onAuthenticationFailure
HttpServletRequest
request.getParameter("username"), where "username" is the name of my input in my HTML form.
request.getParameter("username")
"username"