mirror of
https://codeberg.org/rimu/pyfedi
synced 2025-01-23 19:36:56 -08:00
disallow silly passwords
This commit is contained in:
parent
612f60f12d
commit
686ac36ac7
1 changed files with 3 additions and 0 deletions
|
@ -44,6 +44,9 @@ class RegistrationForm(FlaskForm):
|
|||
if not password.data:
|
||||
return
|
||||
|
||||
if password.data == 'password' or password.data == '12345678' or password.data == '1234567890':
|
||||
raise ValidationError(_l('This password is too common.'))
|
||||
|
||||
first_char = password.data[0] # the first character in the string
|
||||
|
||||
all_the_same = True
|
||||
|
|
Loading…
Add table
Reference in a new issue