[PM-13387] Skip unneeded confirmation button when using passive biometrics such as face unlock #4064
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.
🎟️ Tracking
I opened this discussion explaining the change a few weeks ago:
https://github.com/orgs/bitwarden/discussions/11286
Got no response so far so I decided to go ahead and submit the PR. Hope that's ok!
📔 Objective
As explained in that discussion, by default the Biometrics API treats any authentication as if it were a high-risk operation (such as a purchase), and requires the user to press a "Confirm" button after successful authentication when using a passive biometric system (such as the secure face unlock present in newer Pixels).
But this doesn't really make sense for low-risk operations such as logging into an app, where you'd expect an iPhone-like authentication that seamlessly takes you to the app after success (I question whether it makes sense for the API to default to
true
here, but that's besides this PR).This extremely simple PR just adds the
.setConfirmationRequired(false)
flag to the biometric prompt, which will greatly improve the user experience for people using devices with secure face unlock.📸 Screenshots
The way it currently works, which requires pressing the "Confirm" button after successful face authentication:
The way it should work, showing the face unlock icon but requiring no user interaction to progress into the app activity:
🦮 Reviewer guidelines
:+1:
) or similar for great changes:memo:
) or ℹ️ (:information_source:
) for notes or general info:question:
) for questions:thinking:
) or 💭 (:thought_balloon:
) for more open inquiry that's not quite a confirmedissue and could potentially benefit from discussion
:art:
) for suggestions / improvements:x:
) or:warning:
) for more significant problems or concerns needing attention:seedling:
) or ♻️ (:recycle:
) for future improvements or indications of technical debt:pick:
) for minor or nitpick changes