CsrfRequestHeaderAccessCheck
class CsrfRequestHeaderAccessCheck implements AccessCheckInterface (View source)
Access protection against CSRF attacks.
Constants
| TOKEN_KEY |
A string key that will used to designate the token used by this class. |
Properties
| protected SessionConfigurationInterface | $sessionConfiguration | The session configuration. |
|
| protected CsrfTokenGenerator | $csrfToken | The token generator. |
Methods
__construct(SessionConfigurationInterface $session_configuration, CsrfTokenGenerator $csrf_token)
Constructs a new rest CSRF access check.
bool
applies(Route $route)
Declares whether the access check applies to a specific route or not.
Details
__construct(SessionConfigurationInterface $session_configuration, CsrfTokenGenerator $csrf_token)
Constructs a new rest CSRF access check.
bool
applies(Route $route)
Declares whether the access check applies to a specific route or not.
AccessResultInterface
access(Request $request, AccountInterface $account)
Checks access.