Browse Source

fix: Use `preffered` UVP for passkey registration

pull/7370/head
RaphaelRoumezin 3 weeks ago
parent
commit
f7f2007f7b
No known key found for this signature in database GPG Key ID: 574E114D1538F51B
  1. 2
      src/api/core/webauthn.rs

2
src/api/core/webauthn.rs

@ -141,7 +141,7 @@ async fn post_webauthn_attestation_options(
// requires the credential to be discoverable (resident) so the authenticator can find it // requires the credential to be discoverable (resident) so the authenticator can find it
// without the server providing allowCredentials. // without the server providing allowCredentials.
if let Some(asc) = challenge.public_key.authenticator_selection.as_mut() { if let Some(asc) = challenge.public_key.authenticator_selection.as_mut() {
asc.user_verification = UserVerificationPolicy::Discouraged_DO_NOT_USE; asc.user_verification = UserVerificationPolicy::Preferred;
asc.require_resident_key = true; asc.require_resident_key = true;
asc.resident_key = Some(webauthn_rs_proto::ResidentKeyRequirement::Required); asc.resident_key = Some(webauthn_rs_proto::ResidentKeyRequirement::Required);
} }

Loading…
Cancel
Save