Repository navigation
feat: fill password fields from the Keychain or with approved agent text, and refuse typing or pasting into them otherwise - #122
Closed
iamnbutler wants to merge 7 commits into
Closed
iamnbutler wants to merge 7 commits into
iamnbutler wants to merge 7 commits into
Conversation
iamnbutler
force-pushed
the
feat/caller-approval
branch
from
October 17, 2026 12:23
2335773 to
218fc99
Compare
iamnbutler
force-pushed
the
feat/caller-approval
branch
from
October 17, 2026 12:40
218fc99 to
0d8b806
Compare
Contributor
Author
iamnbutler
added a commit
that referenced
this pull request
Oct 17, 2026
…ext, and refuse typing or pasting into them otherwise (#124) * feat: fill password fields from the Keychain or with approved agent text, and refuse typing or pasting into them otherwise (#117) * docs: link #122 * feat: refuse Paste menu commands while a password field has focus * chore: regenerate the secure fill patch on main * docs: link #124 * chore: regenerate the secure fill patch on main * chore: regenerate the secure fill patch on main * fix: report password-field refusals as refused, with SECURE_FIELD_REQUIRES_FILL or FILL_REFUSED
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.
Implements #117. Stacked on #120 (caller approval): it uses #120's prompt and caller identity, and lands after it.
desktop_fill_passwordfills the password field that has keyboard focus in a snapshot.servicenames a generic password andserveran internet password, with an optionalaccount. The runtime reads the item withSecItemCopyMatching, so macOS asks the user for each item, and the agent never sees it.Confirmations, names the caller (Callers.shared), the app and the site. Always Allow Agent-Supplied Passwords in the menu skips it; it is off by default. After 60 s the prompt is withdrawn withcancel(key:)and the fill is refused.Behavior change. While the live focused element is secure:
desktop_keyrefuses keys that enter characters and Command-V with any modifiers.desktop_insertrefuses every route: type, paste, and attachments.SECURE_FIELD_REQUIRES_FILLand a hint naming the fill tool.desktop_type,set_valueandselecton a secure element now use the same code.desktop_menurefuses a Paste command the same way. The host matches the resolved leaf byAXMenuItemCmdCharV with Command, or anAXIdentifierstarting withpaste, so localized titles are covered.desktop_menubar_clickonly opens a status item and never chooses a menu item, so it needs no check.desktop_click, and drag-and-drop.Native.
peekaboo-secure-fill.patchcomes last, after caller-admission. It adds thesecureTextFillop, its hook, the guard inhandleAuthorized, andHotkeyService.entersText.password.swiftwithdesktop_tools_set_password_autofill,desktop_tools_set_confirmation_handlers(ask, cancel)anddesktop_tools_answer_confirmation.Tests.
npm test: 77 pass, including a new password-fill test.npm run checkis clean.HotkeyEntersTextTests,PeekabooBridgeRequestPlanTests,PeekabooBridgeOperationSemanticPlanTestsandPeekabooBridgeOperationResultSemanticsTestspass (74 tests). The wire count is 134.