|
@@ -42,7 +42,7 @@ class UsernamePasswordFormAuthenticationListener extends AbstractAuthenticationL
|
|
|
'username_parameter' => '_username',
|
|
|
'password_parameter' => '_password',
|
|
|
'csrf_parameter' => '_csrf_token',
|
|
|
- 'csrf_page_id' => 'form_login',
|
|
|
+ 'intention' => 'authenticate',
|
|
|
'post_only' => true,
|
|
|
), $options), $successHandler, $failureHandler, $logger, $dispatcher);
|
|
|
|
|
@@ -65,7 +65,7 @@ class UsernamePasswordFormAuthenticationListener extends AbstractAuthenticationL
|
|
|
if (null !== $this->csrfProvider) {
|
|
|
$csrfToken = $request->get($this->options['csrf_parameter']);
|
|
|
|
|
|
- if (false === $this->csrfProvider->isCsrfTokenValid($this->options['csrf_page_id'], $csrfToken)) {
|
|
|
+ if (false === $this->csrfProvider->isCsrfTokenValid($this->options['intention'], $csrfToken)) {
|
|
|
throw new InvalidCsrfTokenException('Invalid CSRF token.');
|
|
|
}
|
|
|
}
|