[PR #8822] feat(passkey): allow for attestationType: "direct" #25137

Open
opened 2026-04-15 22:44:14 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/8822
Author: @JuanM04
Created: 3/29/2026
Status: 🔄 Open

Base: mainHead: attestationType


📝 Commits (2)

  • 2029537 Allow for attestationType: "direct"
  • bd57d04 Added test to prevent regression

📊 Changes

4 files changed (+43 additions, -1 deletions)

View changed files

📝 docs/content/docs/plugins/passkey.mdx (+5 -0)
📝 packages/passkey/src/passkey.test.ts (+28 -0)
📝 packages/passkey/src/routes.ts (+1 -1)
📝 packages/passkey/src/types.ts (+9 -0)

📄 Description

Following what's described in #6371 (and old PR #2466), this PR allows for attestationType: "direct". This implies always requesting AAGUID from the passkey provider, since with "none" it sometimes defaulted to 00000000-0000-0000-0000-000000000000.


Summary by cubic

Add support for attestationType: "direct" in passkey registration while keeping the default "none". Added tests to ensure the default and forwarding behavior.

  • New Features
    • Add attestationType?: "none" | "direct" to PasskeyOptions.
    • Forward opts.attestationType to registration; fallback to "none".
    • Document attestationType in docs/plugins/passkey.mdx and add tests for default "none" and "direct".

Written for commit bd57d0475a. Summary will update on new commits.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/better-auth/better-auth/pull/8822 **Author:** [@JuanM04](https://github.com/JuanM04) **Created:** 3/29/2026 **Status:** 🔄 Open **Base:** `main` ← **Head:** `attestationType` --- ### 📝 Commits (2) - [`2029537`](https://github.com/better-auth/better-auth/commit/20295370d5968021a583573c5516afcc476fc44e) Allow for `attestationType: "direct"` - [`bd57d04`](https://github.com/better-auth/better-auth/commit/bd57d0475aabf613b59de8ba22e44f9076c72f3c) Added test to prevent regression ### 📊 Changes **4 files changed** (+43 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `docs/content/docs/plugins/passkey.mdx` (+5 -0) 📝 `packages/passkey/src/passkey.test.ts` (+28 -0) 📝 `packages/passkey/src/routes.ts` (+1 -1) 📝 `packages/passkey/src/types.ts` (+9 -0) </details> ### 📄 Description Following what's described in #6371 (and old PR #2466), this PR allows for `attestationType: "direct"`. This implies always requesting AAGUID from the passkey provider, since with `"none"` it sometimes defaulted to `00000000-0000-0000-0000-000000000000`. <!-- This is an auto-generated description by cubic. --> --- ## Summary by cubic Add support for `attestationType: "direct"` in passkey registration while keeping the default `"none"`. Added tests to ensure the default and forwarding behavior. - **New Features** - Add `attestationType?: "none" | "direct"` to `PasskeyOptions`. - Forward `opts.attestationType` to registration; fallback to `"none"`. - Document `attestationType` in `docs/plugins/passkey.mdx` and add tests for default `"none"` and `"direct"`. <sup>Written for commit bd57d0475aabf613b59de8ba22e44f9076c72f3c. Summary will update on new commits.</sup> <!-- End of auto-generated description by cubic. --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-15 22:44:14 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#25137