W3cubDocs

/Symfony 4.1

GuardAuthenticationListener

class GuardAuthenticationListener implements ListenerInterface

Authentication listener for the "guard" system.

Methods

__construct(GuardAuthenticatorHandler $guardHandler, AuthenticationManagerInterface $authenticationManager, string $providerKey, iterable|AuthenticatorInterface[] $guardAuthenticators, LoggerInterface $logger = null)
handle(GetResponseEvent $event)

Iterates over each authenticator to see if each wants to authenticate the request.

setRememberMeServices(RememberMeServicesInterface $rememberMeServices)

Should be called if this listener will support remember me.

Details

__construct(GuardAuthenticatorHandler $guardHandler, AuthenticationManagerInterface $authenticationManager, string $providerKey, iterable|AuthenticatorInterface[] $guardAuthenticators, LoggerInterface $logger = null)

Parameters

GuardAuthenticatorHandler $guardHandler The Guard handler
AuthenticationManagerInterface $authenticationManager An AuthenticationManagerInterface instance
string $providerKey The provider (i.e. firewall) key
iterable|AuthenticatorInterface[] $guardAuthenticators The authenticators, with keys that match what's passed to GuardAuthenticationProvider
LoggerInterface $logger A LoggerInterface instance

handle(GetResponseEvent $event)

Iterates over each authenticator to see if each wants to authenticate the request.

Parameters

GetResponseEvent $event

setRememberMeServices(RememberMeServicesInterface $rememberMeServices)

Should be called if this listener will support remember me.

Parameters

RememberMeServicesInterface $rememberMeServices