LoginLinkAuthenticator
extends AbstractAuthenticator
in package
implements
InteractiveAuthenticatorInterface
FinalYes
An optional base class that creates the necessary tokens for you.
Tags
Table of Contents
Interfaces
- InteractiveAuthenticatorInterface
- This is an extension of the authenticator interface that must be used by interactive authenticators.
Properties
- $failureHandler : mixed
- $httpUtils : mixed
- $loginLinkHandler : mixed
- $options : array<string|int, mixed>
- $successHandler : mixed
Methods
- __construct() : mixed
- authenticate() : Passport
- createToken() : TokenInterface
- Shortcut to create a PostAuthenticationToken for you, if you don't really care about which authenticated token you're using.
- isInteractive() : bool
- Should return true to make this authenticator perform an interactive login.
- onAuthenticationFailure() : Response
- onAuthenticationSuccess() : Response|null
- supports() : bool|null
Properties
$failureHandler
private
mixed
$failureHandler
$httpUtils
private
mixed
$httpUtils
$loginLinkHandler
private
mixed
$loginLinkHandler
$options
private
array<string|int, mixed>
$options
$successHandler
private
mixed
$successHandler
Methods
__construct()
public
__construct(LoginLinkHandlerInterface $loginLinkHandler, HttpUtils $httpUtils, AuthenticationSuccessHandlerInterface $successHandler, AuthenticationFailureHandlerInterface $failureHandler, array<string|int, mixed> $options) : mixed
Parameters
- $loginLinkHandler : LoginLinkHandlerInterface
- $httpUtils : HttpUtils
- $successHandler : AuthenticationSuccessHandlerInterface
- $failureHandler : AuthenticationFailureHandlerInterface
- $options : array<string|int, mixed>
authenticate()
public
authenticate(Request $request) : Passport
Parameters
- $request : Request
Return values
PassportcreateToken()
Shortcut to create a PostAuthenticationToken for you, if you don't really care about which authenticated token you're using.
public
createToken(Passport $passport, string $firewallName) : TokenInterface
Parameters
- $passport : Passport
-
The passport returned from authenticate()
- $firewallName : string
Return values
TokenInterfaceisInteractive()
Should return true to make this authenticator perform an interactive login.
public
isInteractive() : bool
Return values
boolonAuthenticationFailure()
public
onAuthenticationFailure(Request $request, AuthenticationException $exception) : Response
Parameters
- $request : Request
- $exception : AuthenticationException
Return values
ResponseonAuthenticationSuccess()
public
onAuthenticationSuccess(Request $request, TokenInterface $token, string $firewallName) : Response|null
Parameters
- $request : Request
- $token : TokenInterface
- $firewallName : string
Return values
Response|nullsupports()
public
supports(Request $request) : bool|null
Parameters
- $request : Request