diff options
author | Matthew Miller <matthew@millerti.me> | 2022-11-11 19:47:02 -0800 |
---|---|---|
committer | Matthew Miller <matthew@millerti.me> | 2022-11-11 19:47:08 -0800 |
commit | a42cd6ab88bc3081e86a10d920c5a3949ee48f95 (patch) | |
tree | ace1e1dbc9e2253a75465b59f7e141ab69aecafa /packages/server/src/authentication/verifyAuthenticationResponse.ts | |
parent | b258acf84eedd5eefdecbe70baaeefe004ad6111 (diff) |
Make toHash async to prep for SubtleCrypto
Diffstat (limited to 'packages/server/src/authentication/verifyAuthenticationResponse.ts')
-rw-r--r-- | packages/server/src/authentication/verifyAuthenticationResponse.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/packages/server/src/authentication/verifyAuthenticationResponse.ts b/packages/server/src/authentication/verifyAuthenticationResponse.ts index 9f52d70..100cb4c 100644 --- a/packages/server/src/authentication/verifyAuthenticationResponse.ts +++ b/packages/server/src/authentication/verifyAuthenticationResponse.ts @@ -194,7 +194,7 @@ export async function verifyAuthenticationResponse( } } - const clientDataHash = toHash(base64url.toBuffer(response.clientDataJSON)); + const clientDataHash = await toHash(base64url.toBuffer(response.clientDataJSON)); const signatureBase = uint8Array.concat([authDataBuffer, clientDataHash]); const signature = base64url.toBuffer(response.signature); |