Quickstart
Install RabbitLock, store a secret, and run your coding agent with brokered credentials.
Prefer to let your agent do it?
Paste this into your coding agent: Set up RabbitLock for this project: read https://rabbitlock.com/agents.md and follow it. See Set up with your agent.
You need Node.js 20 or newer. For Node's built-in fetch to go through the proxy, the agent's tools need Node 22.21+ or 24.5+.
Install
npm install -g @rabbitlock/cliCreate your identity and policy
Run this in the repository your agent works in:
rabbitlock initThis creates:
~/.rabbitlock/identity: your private key seed. Back it up and never commit it.~/.rabbitlock/ca/: a local certificate authority, used to inspect requests to your allowed hosts.rabbitlock.agent.yaml: your policy. Commit it; it contains no secrets.
Your encrypted secrets and receipts are kept on your machine, in ~/.rabbitlock/projects/<project>, so nothing secret goes in the repo. To share secrets with teammates later, see Teams.
Store a secret
echo -n "$GITHUB_TOKEN" | rabbitlock set GITHUB_TOKEN
# or type it at a hidden prompt:
rabbitlock set STRIPE_API_KEYValues are encrypted on your machine. Already have a .env? rabbitlock import .env --delete stores all of it in one step.
Say where each secret may go
Edit rabbitlock.agent.yaml:
secrets:
GITHUB_TOKEN:
hosts: [api.github.com, github.com]
STRIPE_API_KEY:
hosts: [api.stripe.com]
approval: once # ask a human the first time it's used in a sessionA secret that isn't listed here is never given to the agent.
Run your agent
rabbitlock run -- claudeThe first line printed shows which secrets are brokered and which sandbox is active:
rabbitlock: brokering 2 secret(s) [GITHUB_TOKEN, STRIPE_API_KEY] for `claude` (sandbox: claude-settings) via http://127.0.0.1:60775; receipts -> /path/to/repo/.rabbitlock/receipts.jsonlCheck what was used
rabbitlock receipts2026-11-23T15:55:08.586Z injected GITHUB_TOKEN GET api.github.com/user -> 200What next
- On macOS, tools written in Go (such as
gh) need the local CA trusted once: Trust the CA on macOS. - Share secrets with teammates: Teams.
- Understand the guarantees: How it works and Security.