Package com.axelor.auth.pac4j.local
Class CredentialsHandler
java.lang.Object
com.axelor.auth.pac4j.local.CredentialsHandler
Fires the post-login failure event for credentials rejected by the pac4j clients.
Clients validate credentials themselves, before any Pac4jToken is built and before
Shiro is involved. As a result, such failures never reach a realm and Shiro authentication
listeners are never notified, so the clients have to report the failure themselves.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidhandleInvalidCredentials(org.pac4j.core.client.Client client, String username, org.pac4j.core.exception.CredentialsException e) Fires the post-login failure event for the given rejected credentials.
-
Constructor Details
-
CredentialsHandler
public CredentialsHandler()
-
-
Method Details
-
handleInvalidCredentials
public void handleInvalidCredentials(org.pac4j.core.client.Client client, String username, org.pac4j.core.exception.CredentialsException e) Fires the post-login failure event for the given rejected credentials.A token is built from the submitted username so that listeners observe the same event shape as for logins that did reach Shiro, which is what failed login tracking relies on to identify the account being attempted.
- Parameters:
client- the client that rejected the credentialsusername- the submitted user identifier, may be blank if none was submittede- the exception describing the failure
-