New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@1auth/authn-webauthn

Package Overview
Dependencies
Maintainers
0
Versions
57
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@1auth/authn-webauthn - npm Package Compare versions

Comparing version 0.0.0-alpha.50 to 0.0.0-alpha.51

43

index.js

@@ -36,13 +36,8 @@ import {

verify: async (response, value) => {
try {
const { verified, registrationInfo } = await verifyRegistrationResponse({
...value,
response
})
if (!verified) throw new Error('Failed verifyRegistrationResponse')
return { registrationInfo: jsonEncodeSecret(registrationInfo) }
} catch (e) {
console.error('@1auth/authn-webauthn token.verify()', e)
return false
}
const { verified, registrationInfo } = await verifyRegistrationResponse({
...value,
response
})
if (!verified) throw new Error('Failed verifyRegistrationResponse')
return { registrationInfo: jsonEncodeSecret(registrationInfo) }
}

@@ -89,17 +84,13 @@ }

verify: async (response, value) => {
try {
const { verified, authenticationInfo } =
await verifyAuthenticationResponse({
...value,
credential: value.authenticator.credential,
response
})
if (!verified) throw new Error('Failed verifyAuthenticationResponse')
value.authenticator.credential.counter = authenticationInfo.newCounter
value.authenticator = jsonEncodeSecret(value.authenticator)
return true
} catch (e) {
console.error('@1auth/authn-webauthn challenge.verify()', e)
return false
}
const { verified, authenticationInfo } = await verifyAuthenticationResponse(
{
...value,
credential: value.authenticator.credential,
response
}
)
if (!verified) throw new Error('Failed verifyAuthenticationResponse')
value.authenticator.credential.counter = authenticationInfo.newCounter
value.authenticator = jsonEncodeSecret(value.authenticator)
return true
},

@@ -106,0 +97,0 @@ cleanup: async (sub, value, { sourceId } = {}) => {

{
"name": "@1auth/authn-webauthn",
"version": "0.0.0-alpha.50",
"version": "0.0.0-alpha.51",
"description": "",

@@ -5,0 +5,0 @@ "type": "module",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc