After registering your binary, it starts with no permissions. You control exactly which OS keychain service namespaces your tool can access — and in what ways — by editing its entry inDocumentation Index
Fetch the complete documentation index at: https://theseventeen-2abbdf80.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
~/.config/keychain-auth/config.json. This page explains the permission fields, the scope rules the daemon enforces, and two architectural patterns for structuring your namespaces.
Permission fields in config.json
Each registered binary has three permission fields:allowed_read_services— array of service namespace strings the binary can read from.allowed_write_services— array of service namespace strings the binary can write to and delete from.can_search— boolean that enables search operations and prefix-based bulk reads and deletes.
Permission scopes
The daemon enforces the following rules before executing any keychain operation:- Read — the requested
servicemust be listed inallowed_read_services. - Write — the requested
servicemust be listed inallowed_write_services. - Delete — the requested
servicemust be listed inallowed_write_services. Delete is treated as a write-level privilege. - Search — requires
can_search: trueAND the requestedservicemust be inallowed_read_services. - Prefix read (
"match": "prefix"with"action": "read") — requires the service inallowed_read_servicesANDcan_search: true, because the daemon must enumerate keys to resolve the prefix. - Prefix delete (
"match": "prefix"with"action": "delete") — requires the service inallowed_write_servicesANDcan_search: true.
All checks are pre-flight and all-or-nothing. If your tool requests five targets and any single one is unauthorized, the entire batch is rejected before any keychain operation occurs.
Architectural patterns
There are two common approaches to structuring service namespace permissions. The right choice depends on whether your tool needs to share credentials with other CLI tools.Denied requests
If your tool attempts to access a namespace it is not authorized for, the daemon returns a denial response with areason field explaining the rejection:
service_not_allowed— the service namespace is not in the binary’s read or write list.action_not_in_policy— the binary attempted a search or prefix operation butcan_searchisfalse.unregistered_binary_pending_approval— the binary’s hash does not match any entry inconfig.json.