apple: prefer implicit default keychain; explicit path as fallback#70
Merged
jgowdy-godaddy merged 1 commit intomainfrom Apr 17, 2026
Merged
apple: prefer implicit default keychain; explicit path as fallback#70jgowdy-godaddy merged 1 commit intomainfrom
jgowdy-godaddy merged 1 commit intomainfrom
Conversation
PR #68 made the Swift bridge unconditionally open the login keychain by absolute path and pin every SecItem* op to it via kSecUseKeychain / kSecMatchSearchList. That fixed the "Keychain Not Found" modal dialog on local dev runs that override $HOME in tests, but it made GitHub Actions `macos-latest` jobs hang: SecItemAdd against an explicitly-pinned legacy keychain blocks on a same-binary ACL confirmation prompt the headless runner cannot answer. Fix: check SecKeychainCopyDefault first. When a default keychain is reachable (normal interactive sessions and CI runners), fall through to Security.framework's implicit routing, which reaches the Data Protection keychain on unsigned builds and does not trigger the legacy ACL prompt — restoring the pre-#68 CI behaviour. Only when no default is reachable ($HOME-overridden tests, launchd sandboxes) do we open the login keychain by explicit path and constrain ops to it — preserving #68's dialog-avoidance fix for those contexts.
4 tasks
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
Follow-up to #68 and #69. Root-causes the npmenc macOS CI hang and restores pre-#68 CI behaviour while keeping the `$HOME`-override dialog fix.
Test plan