Repository navigation
Conversation
After a user signs in by typing their password on a Mac with Touch ID, offer once to use Touch ID next time. When it's on, an expired Apple session is restored with a Touch ID prompt instead of the sign-in window, and the sign-in window offers "Sign in with Touch ID". If Touch ID fails, is cancelled, or isn't available, the normal sign-in window is shown. Concurrent session checks share one prompt, and no prompt is shown while the app is in the background. Signing out turns Touch ID off and offers it again on the next sign-in. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
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.
Summary
Apple's servers need the Apple ID password, so Touch ID can't replace it entirely. This change lets Touch ID unlock the password Xcodes already saves in the Keychain, so users type it once and use their fingerprint from then on.
Details
Biometricsdependency onEnvironment, mocked in tests.Localizable.xcstringsin English only, so they need translating.Limitation for maintainers to consider
The Touch ID requirement is enforced by the app, not by macOS: the Keychain item itself isn't protected by biometrics. Making macOS enforce it (
SecAccessControlwith.biometryCurrentSet) requires the data-protection keychain. That in turn needs a keychain-access-groups / application-identifier entitlement and a provisioning profile, which the app doesn't currently have. Existing saved passwords would also need migrating. That seemed like a signing decision for the maintainers rather than something to change in this PR.Testing
AppStateTestsfor: Touch ID success, failure and unavailable; one prompt shared by concurrent callers; no prompt in the background; the sign-in window after a failed prompt at launch; a late result ignored; sign-out resetting Touch ID; and recording the offer answer. The full suite passes (141 tests, 3 skipped).~/Library/HTTPStorages/com.xcodesorg.xcodesapp.binarycookiesto simulate Apple expiring the session. On relaunch, Touch ID signed back in without the sign-in window.🤖 Generated with Claude Code