-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Also limit the password length on reset #35965
Also limit the password length on reset #35965
Conversation
Signed-off-by: Joas Schilling <[email protected]>
/backport to stable25 |
@@ -240,6 +240,10 @@ public function setPassword(string $token, string $userId, string $password, boo | |||
$this->eventDispatcher->dispatchTyped(new BeforePasswordResetEvent($user, $password)); | |||
\OC_Hook::emit('\OC\Core\LostPassword\Controller\LostController', 'pre_passwordReset', ['uid' => $userId, 'password' => $password]); | |||
|
|||
if (strlen($password) > 469) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Magic number? We have no constant/config for this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Magic number for now due to upcoming release and necessary backport.
But yeah it yields for a const.
Scheduled myself a todo for next week
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
Is the issue fixed or can I collabrate to fix this issue?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR at #35981
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
New change in code is fine to me.👍
Ref #33110
Checklist