PHP 클래스 Symfony\Component\Security\Http\Firewall\AbstractAuthenticationListener

Subclasses likely have to implement the following: - an TokenInterface to hold authentication related data - an AuthenticationProvider to perform the actual authentication of the token, retrieve the UserInterface implementation from a database, and perform the specific account checks using the UserChecker By default, this listener only is active for a specific path, e.g. login_check. If you want to change this behavior, you can overwrite the requiresAuthentication() method.
저자: Fabien Potencier ([email protected])
저자: Johannes M. Schmitt ([email protected])
상속: implements Symfony\Component\Security\Http\Firewall\ListenerInterface
파일 보기 프로젝트 열기: pmjones/php-framework-benchmarks 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$authenticationManager
$logger
$options
$providerKey

공개 메소드들

메소드 설명
__construct ( Symfony\Component\Security\Core\SecurityContextInterface $securityContext, Symfony\Component\Security\Core\Authentication\AuthenticationManagerInterface $authenticationManager, Symfony\Component\Security\Http\Session\SessionAuthenticationStrategyInterface $sessionStrategy, HttpUtils $httpUtils, string $providerKey, array $options = [], Symfony\Component\Security\Http\Authentication\AuthenticationSuccessHandlerInterface $successHandler = null, Symfony\Component\Security\Http\Authentication\AuthenticationFailureHandlerInterface $failureHandler = null, Symfony\Component\HttpKernel\Log\LoggerInterface $logger = null, Symfony\Component\EventDispatcher\EventDispatcherInterface $dispatcher = null ) Constructor.
handle ( GetResponseEvent $event ) Handles form based authentication.
setRememberMeServices ( Symfony\Component\Security\Http\RememberMe\RememberMeServicesInterface $rememberMeServices ) Sets the RememberMeServices implementation to use

보호된 메소드들

메소드 설명
attemptAuthentication ( Request $request ) : Symfony\Component\Security\Core\Authentication\Token\TokenInterface Performs authentication.
requiresAuthentication ( Request $request ) : boolean Whether this request requires authentication.

비공개 메소드들

메소드 설명
determineTargetUrl ( Request $request ) : string Builds the target URL according to the defined options.
onFailure ( GetResponseEvent $event, Request $request, Symfony\Component\Security\Core\Exception\AuthenticationException $failed )
onSuccess ( GetResponseEvent $event, Request $request, Symfony\Component\Security\Core\Authentication\Token\TokenInterface $token )

메소드 상세

__construct() 공개 메소드

Constructor.
public __construct ( Symfony\Component\Security\Core\SecurityContextInterface $securityContext, Symfony\Component\Security\Core\Authentication\AuthenticationManagerInterface $authenticationManager, Symfony\Component\Security\Http\Session\SessionAuthenticationStrategyInterface $sessionStrategy, HttpUtils $httpUtils, string $providerKey, array $options = [], Symfony\Component\Security\Http\Authentication\AuthenticationSuccessHandlerInterface $successHandler = null, Symfony\Component\Security\Http\Authentication\AuthenticationFailureHandlerInterface $failureHandler = null, Symfony\Component\HttpKernel\Log\LoggerInterface $logger = null, Symfony\Component\EventDispatcher\EventDispatcherInterface $dispatcher = null )
$securityContext Symfony\Component\Security\Core\SecurityContextInterface A SecurityContext instance
$authenticationManager Symfony\Component\Security\Core\Authentication\AuthenticationManagerInterface An AuthenticationManagerInterface instance
$sessionStrategy Symfony\Component\Security\Http\Session\SessionAuthenticationStrategyInterface
$httpUtils Symfony\Component\Security\Http\HttpUtils An HttpUtilsInterface instance
$providerKey string
$options array An array of options for the processing of a successful, or failed authentication attempt
$successHandler Symfony\Component\Security\Http\Authentication\AuthenticationSuccessHandlerInterface
$failureHandler Symfony\Component\Security\Http\Authentication\AuthenticationFailureHandlerInterface
$logger Symfony\Component\HttpKernel\Log\LoggerInterface A LoggerInterface instance
$dispatcher Symfony\Component\EventDispatcher\EventDispatcherInterface An EventDispatcherInterface instance

attemptAuthentication() 추상적인 보호된 메소드

Performs authentication.
abstract protected attemptAuthentication ( Request $request ) : Symfony\Component\Security\Core\Authentication\Token\TokenInterface
$request Symfony\Component\HttpFoundation\Request A Request instance
리턴 Symfony\Component\Security\Core\Authentication\Token\TokenInterface The authenticated token, or null if full authentication is not possible

handle() 최종 공개 메소드

Handles form based authentication.
final public handle ( GetResponseEvent $event )
$event Symfony\Component\HttpKernel\Event\GetResponseEvent A GetResponseEvent instance

requiresAuthentication() 보호된 메소드

The default implementation only processed requests to a specific path, but a subclass could change this to only authenticate requests where a certain parameters is present.
protected requiresAuthentication ( Request $request ) : boolean
$request Symfony\Component\HttpFoundation\Request
리턴 boolean

setRememberMeServices() 공개 메소드

Sets the RememberMeServices implementation to use
public setRememberMeServices ( Symfony\Component\Security\Http\RememberMe\RememberMeServicesInterface $rememberMeServices )
$rememberMeServices Symfony\Component\Security\Http\RememberMe\RememberMeServicesInterface

프로퍼티 상세

$authenticationManager 보호되어 있는 프로퍼티

protected $authenticationManager

$logger 보호되어 있는 프로퍼티

protected $logger

$options 보호되어 있는 프로퍼티

protected $options

$providerKey 보호되어 있는 프로퍼티

protected $providerKey