mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-10-01 01:36:12 -04:00
Password length check. Fixes #1087
This commit is contained in:
parent
4d0365bca3
commit
557d476001
@ -117,6 +117,11 @@ impl Perform for Register {
|
||||
}
|
||||
}
|
||||
|
||||
// Password length check
|
||||
if data.password.len() > 60 {
|
||||
return Err(APIError::err("invalid_password").into());
|
||||
}
|
||||
|
||||
// Make sure passwords match
|
||||
if data.password != data.password_verify {
|
||||
return Err(APIError::err("passwords_dont_match").into());
|
||||
|
Loading…
Reference in New Issue
Block a user