mirror of
https://github.com/Yubico/yubico-pam.git
synced 2025-02-01 01:52:17 +01:00
Revert "Wait with declaring PAM_SUCCESS on challenge-response until new"
Tollef has argued that the login should not fail if, for example, the disk is full. I'd rather fail on the cautious side and make sure we don't end up always sending the same challenge to the YubiKey, but I'll leave it up to Tollef to decide for now. This reverts commit 14e917ffae52e05121a69a192d03f98090e8ae41. Conflicts: pam_yubico.c
This commit is contained in:
parent
0cf57429a8
commit
319fee4e08
@ -472,9 +472,10 @@ do_challenge_response(struct cfg *cfg, const char *username)
|
||||
|
||||
yubikey_hex_encode(response_hex, (char *)response, response_len);
|
||||
|
||||
if (strcmp(response_hex, expected_response) != 0) {
|
||||
D(("Unexpected C/R response : %s != %s", response_hex, expected_response));
|
||||
ret = PAM_AUTH_ERR;
|
||||
if (strcmp(response_hex, expected_response) == 0) {
|
||||
ret = PAM_SUCCESS;
|
||||
} else {
|
||||
D(("Unexpected C/R response : %s", response_hex));
|
||||
goto out;
|
||||
}
|
||||
|
||||
@ -513,7 +514,6 @@ do_challenge_response(struct cfg *cfg, const char *username)
|
||||
goto out;
|
||||
|
||||
D(("Challenge-response success!"));
|
||||
ret = PAM_SUCCESS;
|
||||
|
||||
out:
|
||||
if (yk_errno) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user