Open
Conversation
Updates `@simplewebauthn/browser` and `@simplewebauthn/server` dependencies to v13.2.2. This upgrade brings improved security and compatibility by aligning with the latest version of the library, addressing potential vulnerabilities and ensuring better integration with modern browser environments. It also changes the way options are passed to `startAuthentication` and `startRegistration` methods. The userID for registration options is now expected to be a Uint8Array. The authenticator's credential ID is no longer base64 encoded.
Updates the WebAuthn verification process to align with changes in the underlying SimpleWebAuthn library. This change streamlines the extraction and usage of credential information, resulting in a cleaner and more maintainable codebase. It simplifies the verification logic by directly passing credential data.
Updates the WebAuthn and Passkey provider documentation to reflect the SimpleWebAuthn v13 API changes. This includes clarifying the required peer dependencies, detailing the differences in the API (credential IDs as base64 strings, `verifyAuthenticationResponse` requiring a `credential` object, and the options shape for browser helpers), and updating the setup instructions accordingly. This ensures developers using these providers with SimpleWebAuthn v13 have accurate and up-to-date information.
Updates the `@simplewebauthn/browser` and `@simplewebauthn/server` peer dependencies to version 13.2.2 in the WebAuthn and Passkey documentation. Clarifies the usage of `@simplewebauthn/browser` dependency, emphasizing that it's only required for custom sign-in pages. Also, mentions that types are now exported from browser and server packages.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
|
@rastislavcore is attempting to deploy a commit to the authjs Team on Vercel. A member of the Team first needs to authorize it. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
☕️ Reasoning
This PR upgrades WebAuthn / Passkey support to SimpleWebAuthn v13 and keeps docs and tests in sync.
This will make it production ready instead of deprecated version.
Package updates
API and implementation changes (v13)
userIDis now aUint8Array(encoded viaTextEncoder); credential IDs inallowCredentials/excludeCredentialsare base64 strings (a.credentialID).credential(WebAuthnCredential:id,publicKey,counter) instead ofauthenticator. AddadapterAuthenticatorToWebAuthnCredential()and ensurepublicKeyis anArrayBuffer-backedUint8Arrayfor type compatibility.registrationInfoshape:credential(id, publicKey, counter) and top-levelcredentialDeviceType/credentialBackedUp.webauthn-client.js):startAuthenticationandstartRegistrationnow take a single options object (optionsJSON,useBrowserAutofill/useAutoRegister).ConfigurableVerifyAuthenticationOptionsomitscredentialinstead ofauthenticator. Remove unusedfromAdapterAuthenticator.Tests
registrationInfo.credential,credentialin auth verification,CredentialDeviceType,Uint8ArrayforpublicKey).provider.id === "passkey".Documentation
passkey.ts,webauthn.ts): document both peer deps, v13.2.2 install, and a short “SimpleWebAuthn v13” note (credential IDs,credentialusage, browser API shape).docs/pages/getting-started/providers/passkey.mdxanddocs/pages/getting-started/authentication/webauthn.mdxto install@^13.2.2, mention v13 and that types live in browser/server. Fix typo@simplewebauth/browser→@simplewebauthn/browser.🧢 Checklist
🎫 Affected issues
📌 Resources