diff --git a/config/packages/security.yaml b/config/packages/security.yaml index 5234e8100..8cb7e4242 100644 --- a/config/packages/security.yaml +++ b/config/packages/security.yaml @@ -50,6 +50,10 @@ security: # The name of the route to redirect to after logging out target: homepage + # Secure the logout against CSRF + csrf_parameter: logout + csrf_token_generator: security.csrf.token_manager + # needed because in tests we redefine the 'main' firewall to use # HTTP Basic instead of the login form, so this firewall has # multiple authenticators diff --git a/templates/base.html.twig b/templates/base.html.twig index 4f3cfef96..3bbec549c 100644 --- a/templates/base.html.twig +++ b/templates/base.html.twig @@ -83,7 +83,7 @@