SimplePreAuthenticationListener
extends AbstractListener
in package
implements
ListenerInterface
Uses
LegacyListenerTrait
SimplePreAuthenticationListener implements simple proxying to an authenticator.
Tags
Interfaces, Classes, Traits and Enums
- ListenerInterface
- Interface that must be implemented by firewall listeners.
Table of Contents
- $authenticationManager : mixed
- $dispatcher : mixed
- $logger : mixed
- $providerKey : mixed
- $sessionStrategy : mixed
- $simpleAuthenticator : mixed
- $tokenStorage : mixed
- $trustResolver : mixed
- __construct() : mixed
- __invoke() : mixed
- authenticate() : mixed
- Handles basic authentication.
- setSessionAuthenticationStrategy() : mixed
- Call this method if your authentication token is stored to a session.
- supports() : bool|null
- Tells whether the authenticate() method should be called or not depending on the incoming request.
- migrateSession() : mixed
Properties
$authenticationManager
private
mixed
$authenticationManager
$dispatcher
private
mixed
$dispatcher
$logger
private
mixed
$logger
$providerKey
private
mixed
$providerKey
$sessionStrategy
private
mixed
$sessionStrategy
$simpleAuthenticator
private
mixed
$simpleAuthenticator
$tokenStorage
private
mixed
$tokenStorage
$trustResolver
private
mixed
$trustResolver
Methods
__construct()
public
__construct(TokenStorageInterface $tokenStorage, AuthenticationManagerInterface $authenticationManager, string $providerKey, SimplePreAuthenticatorInterface $simpleAuthenticator[, LoggerInterface $logger = null ][, EventDispatcherInterface $dispatcher = null ][, AuthenticationTrustResolverInterface $trustResolver = null ]) : mixed
Parameters
- $tokenStorage : TokenStorageInterface
- $authenticationManager : AuthenticationManagerInterface
- $providerKey : string
- $simpleAuthenticator : SimplePreAuthenticatorInterface
- $logger : LoggerInterface = null
- $dispatcher : EventDispatcherInterface = null
- $trustResolver : AuthenticationTrustResolverInterface = null
Return values
mixed —__invoke()
public
final __invoke(RequestEvent $event) : mixed
Parameters
- $event : RequestEvent
Return values
mixed —authenticate()
Handles basic authentication.
public
authenticate(RequestEvent $event) : mixed
Parameters
- $event : RequestEvent
Return values
mixed —setSessionAuthenticationStrategy()
Call this method if your authentication token is stored to a session.
public
setSessionAuthenticationStrategy(SessionAuthenticationStrategyInterface $sessionStrategy) : mixed
Parameters
- $sessionStrategy : SessionAuthenticationStrategyInterface
Tags
Return values
mixed —supports()
Tells whether the authenticate() method should be called or not depending on the incoming request.
public
supports(Request $request) : bool|null
Returning null means authenticate() can be called lazily when accessing the token storage.
Parameters
- $request : Request
Return values
bool|null —migrateSession()
private
migrateSession(Request $request, TokenInterface $token) : mixed
Parameters
- $request : Request
- $token : TokenInterface