Skip to content

Commit

Permalink
Merge pull request keepassxreboot#2082 from keepassxreboot/fix/passke…
Browse files Browse the repository at this point in the history
…ys_userverification_defaults

Passkeys: Set userVerification to default value if not found
  • Loading branch information
varjolintu committed Jan 15, 2024
2 parents 0a2b461 + c4a578e commit 2c07677
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions keepassxc-browser/content/passkeys-utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@ kpxcPasskeysUtils.buildCredentialCreationOptions = function(pkOptions) {
const publicKey = {};
publicKey.attestation = pkOptions.attestation || 'none';
publicKey.authenticatorSelection = pkOptions.authenticatorSelection || { userVerification: 'preferred' };
if (!publicKey.authenticatorSelection.userVerification) {
publicKey.authenticatorSelection.userVerification = 'preferred';
}

publicKey.challenge = arrayBufferToBase64(pkOptions.challenge);
publicKey.extensions = pkOptions.extensions;
publicKey.pubKeyCredParams = pkOptions.pubKeyCredParams;
Expand Down

0 comments on commit 2c07677

Please sign in to comment.