mirror of
https://github.com/nextcloud/server.git
synced 2026-04-22 23:03:00 -04:00
fix: Use login name to check the password
Signed-off-by: Louis Chemineau <louis@chmn.me>
This commit is contained in:
parent
ff9538302b
commit
81e70c99cb
1 changed files with 2 additions and 1 deletions
|
|
@ -80,7 +80,8 @@ class PasswordConfirmationMiddleware extends Middleware {
|
|||
if ($this->isPasswordConfirmationStrict($reflectionMethod)) {
|
||||
$authHeader = $this->request->getHeader('Authorization');
|
||||
[, $password] = explode(':', base64_decode(substr($authHeader, 6)), 2);
|
||||
$loginResult = $this->userManager->checkPassword($user->getUid(), $password);
|
||||
$loginName = $this->session->get('loginname');
|
||||
$loginResult = $this->userManager->checkPassword($loginName, $password);
|
||||
if ($loginResult === false) {
|
||||
throw new NotConfirmedException();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue