Repository navigation
feat(auth): offer a passkey once during app sign-in - #58
Merged
Merged
Conversation
After signing in on the way to an application, someone without a passkey is asked once to add one. Adding it or skipping continues the same sign-in; a skip is recorded so the offer never returns.
Contributor
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 36 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
lorenzocorallo
approved these changes
Oct 15, 2026
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.
What
People rarely visit the IdP home page; they come through an app's sign-in. Now, right after signing in on the way to an app, someone without a passkey sees one screen offering to add a passkey. Adding one or choosing Skip carries on with the same sign-in, to consent or straight back to the app.
user.passkey_prompt_declined_at(migration0021), and the offer never shows again.postLoginstep (/passkey), so the signed OAuth request is carried through andoauth2/continueresumes it.Guards
prompt=noneis never interrupted. Showing the offer there would make an app's silent sign-in fail withinteraction_required.freshAgerefuses older sessions.freshAgeis now set explicitly to the default (24h) so the two use the same value.continuewould loop back to the offer. This isn't stored as a skip, because the person never saw the offer./passkeywithout a signed request redirects to/.Testing
vp checkandvp testpass. New unit tests covershouldOfferPasskey./passkey./passkey.prompt=nonereturnsconsent_required, notinteraction_required.authClient.passkey.addPasskey()as the account page.Out of scope: people who sign in directly on the IdP home page still add passkeys from the account page's Passkeys panel. The offer only appears during app sign-ins.