Limit maximum length of passwords to 4096 characters

This commit is contained in:
Raphael Michel
2022-01-25 17:24:48 +01:00
parent 73ab962e16
commit 4262bce2b5
3 changed files with 13 additions and 2 deletions

View File

@@ -146,7 +146,8 @@ class NativeAuthBackend(BaseAuthBackend):
d = OrderedDict([
('email', forms.EmailField(label=_("E-mail"), max_length=254,
widget=forms.EmailInput(attrs={'autofocus': 'autofocus'}))),
('password', forms.CharField(label=_("Password"), widget=forms.PasswordInput)),
('password', forms.CharField(label=_("Password"), widget=forms.PasswordInput,
max_length=4096)),
])
return d