Skip to content

Commit f4a7283

Browse files
GromNaNfabpot
authored andcommitted
Hide sensitive information with SensitiveParameter attribute
1 parent f5f40bc commit f4a7283

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Controller/AbstractController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -374,7 +374,7 @@ protected function getUser(): ?UserInterface
374374
* @param string $id The id used when generating the token
375375
* @param string|null $token The actual token sent with the request that should be validated
376376
*/
377-
protected function isCsrfTokenValid(string $id, ?string $token): bool
377+
protected function isCsrfTokenValid(string $id, #[\SensitiveParameter] ?string $token): bool
378378
{
379379
if (!$this->container->has('security.csrf.token_manager')) {
380380
throw new \LogicException('CSRF protection is not enabled in your application. Enable it with the "csrf_protection" key in "config/packages/framework.yaml".');

0 commit comments

Comments
 (0)