SessionAuthenticationStrategy
in package
implements
SessionAuthenticationStrategyInterface
The default session strategy implementation.
Supports the following strategies: NONE: the session is not changed MIGRATE: the session id is updated, attributes are kept INVALIDATE: the session id is updated, attributes are lost
Tags
Table of Contents
Interfaces
- SessionAuthenticationStrategyInterface
- SessionAuthenticationStrategyInterface.
Constants
- INVALIDATE = 'invalidate'
- MIGRATE = 'migrate'
- NONE = 'none'
Properties
- $csrfTokenStorage : ClearableTokenStorageInterface|null
- $strategy : string
Methods
- __construct() : mixed
- onAuthentication() : mixed
- This performs any necessary changes to the session.
Constants
INVALIDATE
public
mixed
INVALIDATE
= 'invalidate'
MIGRATE
public
mixed
MIGRATE
= 'migrate'
NONE
public
mixed
NONE
= 'none'
Properties
$csrfTokenStorage
private
ClearableTokenStorageInterface|null
$csrfTokenStorage
= null
$strategy
private
string
$strategy
Methods
__construct()
public
__construct(string $strategy[, ClearableTokenStorageInterface $csrfTokenStorage = null ]) : mixed
Parameters
- $strategy : string
- $csrfTokenStorage : ClearableTokenStorageInterface = null
onAuthentication()
This performs any necessary changes to the session.
public
onAuthentication(Request $request, TokenInterface $token) : mixed
Parameters
- $request : Request
- $token : TokenInterface