Skip to content

Conversation

@mattcreaser
Copy link
Member

Issue #, if available:

Description of changes:
If the user has already selected an auth factor then Amplify/Cognito doesn't allow you change the selection, but our passwordless UX does allow it. To support this we will keep track of whether the user has already selected an auth factor and, if they have, we will restart the flow with a preferred first factor instead.

So in summary:

  • The first time a user selects an auth factor during signIn call confirmSignIn as normal.
  • Any subsequent times an auth factor is selected call signIn with the selected factor as "preferred".

How did you test these changes?
(Please add a line here how the changes were tested)

Documentation update required?

  • No
  • Yes (Please include a PR link for the documentation update)

General Checklist

  • Added Unit Tests
  • Added Integration Tests
  • Security oriented best practices and standards are followed (e.g. using input sanitization, principle of least privilege, etc)
  • Ensure commit message has the appropriate scope (e.g fix(liveness): message, fix(authenticator): message, fix(all): message)

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@mattcreaser mattcreaser requested review from a team as code owners November 10, 2025 19:45
return
}

// Use has not selected an auth factor yet.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not a big deal, but typo here.

Base automatically changed from mattcreaser/passwordless-passkey-prompt to feat/passwordless November 12, 2025 14:55
@mattcreaser mattcreaser force-pushed the mattcreaser/retry-auth-factor-selection branch from 81bbfed to f08fede Compare November 12, 2025 15:06
@mattcreaser mattcreaser merged commit 58eb248 into feat/passwordless Nov 12, 2025
@mattcreaser mattcreaser deleted the mattcreaser/retry-auth-factor-selection branch November 12, 2025 16:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants