mirror of
https://github.com/signalapp/Signal-Server
synced 2026-04-20 17:58:03 +01:00
Add an explicit "incorrect password" authentication failure reason
This commit is contained in:
committed by
Jon Chambers
parent
0871d6ebc1
commit
138b368951
@@ -108,9 +108,10 @@ public class AccountAuthenticator implements Authenticator<BasicCredentials, Aut
|
||||
SaltedTokenHash.generateFor(basicCredentials.getPassword())); // new credentials have current version
|
||||
}
|
||||
return Optional.of(new AuthenticatedAccount(authenticatedAccount, device.get()));
|
||||
} else {
|
||||
failureReason = "incorrectPassword";
|
||||
return Optional.empty();
|
||||
}
|
||||
|
||||
return Optional.empty();
|
||||
} catch (IllegalArgumentException | InvalidAuthorizationHeaderException iae) {
|
||||
failureReason = "invalidHeader";
|
||||
return Optional.empty();
|
||||
|
||||
Reference in New Issue
Block a user