Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit0e14ecf

Browse files
committed
[Security] Enforce maximum username length
1 parentf444462 commit0e14ecf

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

‎security/custom_authenticator.rst‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,11 @@ using :ref:`the user provider <security-user-providers>`::
205205
// ...
206206
$passport = new Passport(new UserBadge($email), $credentials);
207207

208+
..note::
209+
210+
The maximum length allowed for the user identifier is 4096 characters to
211+
prevent `session storage flooding`_ attacks.
212+
208213
..note::
209214

210215
You can optionally pass a user loader as second argument to the
@@ -373,3 +378,5 @@ authenticator methods (e.g. ``createToken()``)::
373378
return new CustomOauthToken($passport->getUser(), $passport->getAttribute('scope'));
374379
}
375380
}
381+
382+
.. _`session storage flooding`:https://symfony.com/blog/cve-2016-4423-large-username-storage-in-session

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp