1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2025-01-26 10:03:40 +03:00

homework: fix return codes when using fido2/pkcs11 cached passwords

Otherwise we'll accidently report a record we can safely decrypt as not
decrypted.
This commit is contained in:
Lennart Poettering 2021-05-31 22:15:48 +02:00
parent bfc0cc1a25
commit e49614278d

View File

@ -127,7 +127,7 @@ int user_record_authenticate(
return log_error_errno(r, "Failed to check supplied FIDO2 password: %m");
if (r > 0) {
log_info("Previously acquired FIDO2 password unlocks user record.");
return 0;
return 1;
}
}
}
@ -180,7 +180,7 @@ int user_record_authenticate(
if (r < 0)
return log_oom();
return 0;
return 1;
}
#else
need_token = true;