redact-proxy pre-release
Docs menu

CLI and flags

One binary, redactproxy. The commands you run are launch, login, discover, approvals and completion. The rest run inside the containers.

Commands#

CommandWhat it does
launchScrubs the workspace, builds the agent image, starts the sandbox, runs the self-test.
login [-agent-base]Gets the sandbox its own Claude subscription token and stores it in the Keychain.
discoverLists values in the workspace's configuration worth treating as secrets.
approvalsLists and decides queued put-backs, between sessions.
completion bash|zshPrints a shell completion script.

launch#

shell
redactproxy launch -workspace . -policy-file policy.json
FlagDefaultMeaning
-workspace.The workspace the agent works in, at /workspace.
-policy-filerequiredThe policy.
-state-dir~/.redactproxy/<project>Where the store, the CA and the Compose file live.
-proxy-imageredactproxy-proxy:latestThe proxy image (make images).
-agent-baseredactproxy-agent-base:latestThe agent's base image; the CA is added on top. Its label redactproxy.agent.command names the command the launcher tells you to run.
-env-fileThe agent's environment, NAME=value lines, scrubbed before use.
-mount host:agentA credential file the agent gets as a scrubbed, read-only copy. Repeatable.
-ssh-keyAn unencrypted SSH private key for the agent's ssh-agent socket. The key stays in the proxy. Repeatable.
-upstreamhttps://api.anthropic.comAnthropic API base URL.
-upstream-ca-filePEM certificates of private CAs for allowlisted hosts.
-allowed-urlAn allowlisted HTTPS URL; the self-test checks which tools trust the proxy CA against it.

The launcher passes your host's effective git identity for that repository (user.name, user.email) to the proxy's git as the committer.

login#

shell
redactproxy login

Runs claude setup-token in a container of the agent base image (-agent-base, default redactproxy-agent-base:latest). You sign in through the link, then paste the token once; it goes into the Keychain (service redactproxy, account claude-oauth-token). A first launch without credentials runs this itself when you're at a terminal.

discover#

shell
redactproxy discover -workspace .
redactproxy discover -workspace . -kube-context my-context
redactproxy discover -workspace . -out declared.json
Not wired up yet

launch does not read a declared-secrets file; only the proxy's own -declared-file flag does.

approvals#

shell
redactproxy approvals -store <state>/store.bin -store-key-file <file> -container-id <id> list
redactproxy approvals -store <state>/store.bin -store-key-file <file> -container-id <id> approve N
redactproxy approvals -store <state>/store.bin -store-key-file <file> -container-id <id> deny N

Runs while no proxy is using the store. -store-key-file holds the store key as 64 hex characters; the container ID is in <state>/container-id. See approvals.

Inside the containers#

These are run by the images and the launcher, not by you: firewall, routes, scrub, selftest, unpack gitpack|gzip|zip, health. With no subcommand, redactproxy is the proxy itself; the launcher sets its flags (-listen, -dns-listen, -gateway-listen, -git-listen, -policy-file, -store, -store-key-file and others). Two worth knowing: -declared-file (declared secrets) and -dump-limit (personal-data values per tool result before it is withheld, default 50).

Make targets#

TargetWhat it does
make buildgo build -o bin/redactproxy ./cmd/redactproxy
make imagesBuilds redactproxy-proxy:latest and redactproxy-agent-base:latest.
make testgo test ./...
make test-linuxThe test suite in a Linux container, then the firewall rules and routes in real network namespaces.
make e2eEnd to end: the launcher, both containers and the routes helper.
make e2e-servicesEnd to end against local images of Grafana, Meilisearch, PostgreSQL, MongoDB and SQL Server. The HTTP services work; database logins with a marker password are a recorded gap.
Old targets

up, up-real, down, logs, try, demo, agent and secrets drive an older development setup in compose.yaml (LLM path only, mock upstream, no gateway). They are not how the product runs; use launch.