diff options
author | Matthew Miller <matthew@millerti.me> | 2022-12-27 21:56:14 -0800 |
---|---|---|
committer | Matthew Miller <matthew@millerti.me> | 2022-12-27 21:56:14 -0800 |
commit | 08f7f69b221ce33b4bfa6108493fe20d0b7f93b0 (patch) | |
tree | 686adb3a370e68f76541400740a0b722350d8705 /packages/server/src | |
parent | ad5e7119317ab5915c7063b575e2bdd4fe263f9e (diff) |
Revert renaming of registration credentialType
Diffstat (limited to 'packages/server/src')
-rw-r--r-- | packages/server/src/registration/verifyRegistrationResponse.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/packages/server/src/registration/verifyRegistrationResponse.ts b/packages/server/src/registration/verifyRegistrationResponse.ts index 29f6025..2546813 100644 --- a/packages/server/src/registration/verifyRegistrationResponse.ts +++ b/packages/server/src/registration/verifyRegistrationResponse.ts @@ -64,7 +64,7 @@ export async function verifyRegistrationResponse( requireUserVerification = true, supportedAlgorithmIDs = supportedCOSEAlgorithmIdentifiers, } = options; - const { id, rawId, type: responseType, response: attestationResponse } = response; + const { id, rawId, type: credentialType, response: attestationResponse } = response; // Ensure credential specified an ID if (!id) { @@ -77,8 +77,8 @@ export async function verifyRegistrationResponse( } // Make sure credential type is public-key - if (responseType !== 'public-key') { - throw new Error(`Unexpected credential type ${responseType}, expected "public-key"`); + if (credentialType !== 'public-key') { + throw new Error(`Unexpected credential type ${credentialType}, expected "public-key"`); } const clientDataJSON = decodeClientDataJSON(attestationResponse.clientDataJSON); @@ -241,7 +241,7 @@ export async function verifyRegistrationResponse( aaguid: convertAAGUIDToString(aaguid), credentialID, credentialPublicKey, - credentialType: responseType, + credentialType, attestationObject, userVerified: flags.uv, credentialDeviceType, |