Skip to content

Commit 5f38c90

Browse files
-
1 parent 3432d7e commit 5f38c90

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

security/access_denied_handler.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,12 +162,12 @@ configure a :ref:`kernel.exception listener <use-kernel-exception-event>`::
162162
{
163163
public static function getSubscribedEvents(): array
164164
{
165-
return App::config([
165+
return [
166166
// the priority must be greater than the Security HTTP
167167
// ExceptionListener, to make sure it's called before
168168
// the default exception listener
169169
KernelEvents::EXCEPTION => ['onKernelException', 2],
170-
]);
170+
];
171171
}
172172

173173
public function onKernelException(ExceptionEvent $event): void

security/csrf.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ for more information):
5959
# config/packages/framework.yaml
6060
framework:
6161
# ...
62-
csrf_protection: ~
62+
csrf_protection: true
6363
6464
.. code-block:: php
6565
@@ -68,7 +68,7 @@ for more information):
6868
6969
return App::config([
7070
'framework' => [
71-
'csrf_protection' => null,
71+
'csrf_protection' => true,
7272
],
7373
]);
7474
@@ -346,7 +346,7 @@ in applications using :ref:`Symfony Flex <symfony-flex>`.
346346
347347
return App::config([
348348
'framework' => [
349-
'csrf_protection' => [
349+
'csrf_protection' => [
350350
'stateless_token_ids' => ['submit', 'authenticate', 'logout'],
351351
],
352352
],
@@ -395,7 +395,7 @@ own services), and it sets ``submit`` as their default token identifier:
395395
396396
return App::config([
397397
'framework' => [
398-
'form' => [
398+
'form' => [
399399
'csrf_protection' => [
400400
'token_id' => 'submit',
401401
],

security/impersonating_user.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ listener:
2525
firewalls:
2626
main:
2727
# ...
28-
switch_user: true
28+
switch_user: []
2929
3030
.. code-block:: php
3131
@@ -37,7 +37,7 @@ listener:
3737
// ...
3838
'firewalls' => [
3939
'main' => [
40-
'switch_user' => true,
40+
'switch_user' => [],
4141
],
4242
],
4343
],

0 commit comments

Comments
 (0)