Form action will be j_spring_security_check that take the form to spring authentication. Username text name and password field will be like j_username and j_password. By this name in built spring authentication process will fetch the given input.

Custom Error Message in Spring Security

For the custom error message, we need to declare query string parameter as login_error=1 in &ltform-login/&gt. It has been declared in our example as