mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-05 19:42:24 +02:00
feat: add user password constraints (#6945)
* feat: add user password length constraints
* add password length changes in locale files
* revert maximum password length changes
* add tests
* fix lint
* fix lint and test
* fix tests
* Revert "add password length changes in locale files"
This reverts commit eaaf63ba7c
.
* Update PR
---------
Co-authored-by: Chocobozzz <me@florianbigard.com>
This commit is contained in:
parent
eedfb8b0a2
commit
efa32646ed
23 changed files with 195 additions and 76 deletions
|
@ -397,6 +397,15 @@ class ServerConfigManager {
|
|||
|
||||
nsfwFlagsSettings: {
|
||||
enabled: CONFIG.NSFW_FLAGS_SETTINGS.ENABLED
|
||||
},
|
||||
|
||||
fieldsConstraints: {
|
||||
users: {
|
||||
password: {
|
||||
minLength: CONSTRAINTS_FIELDS.USERS.PASSWORD.min,
|
||||
maxLength: CONSTRAINTS_FIELDS.USERS.PASSWORD.max
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -423,7 +432,7 @@ class ServerConfigManager {
|
|||
minimumAge: CONFIG.SIGNUP.MINIMUM_AGE,
|
||||
requiresApproval: CONFIG.SIGNUP.REQUIRES_APPROVAL,
|
||||
requiresEmailVerification: CONFIG.SIGNUP.REQUIRES_EMAIL_VERIFICATION
|
||||
}
|
||||
} satisfies ServerConfig['signup']
|
||||
|
||||
const htmlConfig = await this.getHTMLServerConfig()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue