All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.valkyriercp.security.AuthenticationFailedEvent Maven / Gradle / Ivy

There is a newer version: 1.3
Show newest version
package org.valkyriercp.security;

import org.springframework.security.core.Authentication;
import org.springframework.security.core.AuthenticationException;

/**
 * Event fired when an authentication attempt fails.
 * 

* The source of this event is the Authentication token that resulted in * the authentication failure. This event also carries the exception that indicated the * failure, {@see #getCause()}. * * @author Larry Streepy */ public class AuthenticationFailedEvent extends ClientSecurityEvent { private AuthenticationException cause; /** * Constructor. Use the given authentication token as the source of the event. * @param authentication token * @param cause The exception that caused the login failure */ public AuthenticationFailedEvent(Authentication authentication, AuthenticationException cause) { super( authentication ); setCause( cause ); } /** * Get the exception that caused the login failure * @return causing exception */ public AuthenticationException getCause() { return cause; } /** * Set the exception that caused this login failure. * @param cause */ public void setCause(AuthenticationException cause) { this.cause = cause; } }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy