Skip to content

Commit c7d3bf8

Browse files
committed
feature #19255 Add #[IsCsrfTokenValid] to attributes reference (OskarStark)
This PR was merged into the 7.1 branch. Discussion ---------- Add `#[IsCsrfTokenValid]` to attributes reference Follows * #19254 Commits ------- 7b47bdc Add `#[IsCsrfTokenValid]` to attributes reference
2 parents de48c55 + 7b47bdc commit c7d3bf8

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

reference/attributes.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ Security
8080
~~~~~~~~
8181

8282
* :ref:`CurrentUser <security-json-login>`
83+
* :ref:`IsCsrfTokenValid <csrf-controller-attributes>`
8384
* :ref:`IsGranted <security-securing-controller-attributes>`
8485

8586
Serializer

security/csrf.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,8 @@ method to check its validity::
164164
}
165165
}
166166

167+
.. _csrf-controller-attributes:
168+
167169
Alternatively you can use the
168170
:class:`Symfony\\Component\\Security\\Http\\Attribute\\IsCsrfTokenValid`
169171
attribute on the controller action::

0 commit comments

Comments
 (0)