CsrfTokenManager::getToken()

CsrfToken getToken(string $tokenId)

Returns a CSRF token for the given ID.

If previously no token existed for the given ID, a new token is generated. Otherwise the existing token is returned (with the same value, not the same instance).

Parameters

string $tokenId The token ID. You may choose an arbitrary value for the ID

Return Value

CsrfToken The CSRF token
doc_Symfony
2025-01-10 15:47:30
Comments
Leave a Comment

Please login to continue.