class SimpleAuthenticationHandler implements AuthenticationFailureHandlerInterface, AuthenticationSuccessHandlerInterface
Class to proxy authentication success/failure handlers.
Events are sent to the SimpleAuthenticatorInterface if it implements the right interface, otherwise (or if it fails to return a Response) the default handlers are triggered.
protected | $successHandler | ||
protected | $failureHandler | ||
protected | $simpleAuthenticator | ||
protected | $logger |
__construct(SimpleAuthenticatorInterface $authenticator, AuthenticationSuccessHandlerInterface $successHandler, AuthenticationFailureHandlerInterface $failureHandler, LoggerInterface $logger = null) | ||
Response | onAuthenticationSuccess(Request $request, TokenInterface $token) This is called when an interactive authentication attempt succeeds. This is called by authentication listeners inheriting from AbstractAuthenticationListener. | |
Response | onAuthenticationFailure(Request $request, AuthenticationException $exception) This is called when an interactive authentication attempt fails. This is called by authentication listeners inheriting from AbstractAuthenticationListener. |
SimpleAuthenticatorInterface | $authenticator | SimpleAuthenticatorInterface instance |
AuthenticationSuccessHandlerInterface | $successHandler | Default success handler |
AuthenticationFailureHandlerInterface | $failureHandler | Default failure handler |
LoggerInterface | $logger | Optional logger |
This is called when an interactive authentication attempt succeeds. This is called by authentication listeners inheriting from AbstractAuthenticationListener.
Request | $request | |
TokenInterface | $token |
Response | never null |
This is called when an interactive authentication attempt fails. This is called by authentication listeners inheriting from AbstractAuthenticationListener.
Request | $request | |
AuthenticationException | $exception |
Response | The response to return, never null |
© 2004–2017 Fabien Potencier
Licensed under the MIT License.
https://api.symfony.com/4.1/Symfony/Component/Security/Http/Authentication/SimpleAuthenticationHandler.html