Daemon Proxy
The daemon is a local HTTPS forward proxy between your agent and the LLM provider. It strips real credentials out of outbound requests and resolves them back in responses — the LLM only ever sees clawise://<short_id> placeholders.
Your
agent
sk_live_xxx9zKmsk_live_xxx9zKmmaster keyclawise://a3f7b2c4clawise://a3f7b2c4Setup
1. Start the daemon
clawise daemon startListens on 127.0.0.1:9800. Leave it running.
2. Point your agent at the daemon
In the shell where your agent runs:
export HTTPS_PROXY=http://127.0.0.1:9800
export HTTP_PROXY=http://127.0.0.1:9800
export NODE_EXTRA_CA_CERTS=$(clawise daemon status --ca-path)Your existing LLM client code stays unchanged.
What it does
The daemon does two passes on every request:
- On the way out (agent → LLM): scans the request body and replaces any real credential with a
clawise://<short_id>placeholder. Two sources of matches:- Values already stored in your vault
- New secrets caught by built-in regex — auto-stored in the vault before substitution
- On the way back (LLM → agent, including SSE): scans the response stream for any
clawise://<short_id>echoed back and resolves each one to its plaintext before it reaches your agent.
The LLM and its provider only ever see placeholders. Your agent keeps using plaintext on both sides.
Supported LLM hosts
The daemon only touches traffic to a curated list of LLM provider hosts. Everything else passes through as opaque tunnels and is never read.
Built-in hosts:
api.openai.com,chatgpt.comapi.anthropic.comcloudcode-pa.googleapis.comapi.deepseek.com,api.moonshot.cn,api.minimaxi.com,open.bigmodel.cn,dashscope.aliyuncs.comapi.x.ai,api.groq.com,api.together.xyz,openrouter.aiapi.githubcopilot.comlocalhost:11434(Ollama)
To add your own (e.g., an internal LLM gateway), append one host per line to ~/.local/share/clawise/proxy-whitelist.txt (lines starting with # are comments) and restart the daemon.
Recognized credential formats
For each request to a supported host, the daemon scans the body with a set of built-in regex patterns. When one matches, the secret is auto-stored in the vault, assigned a short ID, and replaced with the placeholder before forwarding.
| Category | Examples |
|---|---|
| LLM provider keys | OpenAI (sk-...T3BlbkFJ...), Anthropic (sk-ant-...), Google (AIza...), DeepSeek, Groq, Together, Fireworks, OpenRouter, Perplexity, xAI, Replicate, HuggingFace |
| Cloud | AWS access keys, AWS secret access keys, Google OAuth client secrets |
| Source control | GitHub tokens (ghp_, ghu_, gho_, ghs_), GitHub fine-grained PATs, GitLab PATs / CI tokens |
| Messaging | Slack bot / user / app tokens |
| Payments | Stripe secret / publishable / webhook secrets |
| Generic | JWT-like strings, npm tokens, PyPI tokens |
The full pattern list is built into the binary and updated as new formats become relevant.
Custom rules
Override defaults in ~/.config/clawise/config.yaml. The daemon watches the file and reloads on save (or send SIGHUP manually):
daemon:
rules:
disable_default: false
blocklist:
- 'INTERNAL_API_[A-Z0-9]{32}'
- 'corp-secret-[a-f0-9]{16}'
allowlist:
- 'PUBLIC_KEY_[A-Z0-9]+'
vendor_schemas:
- host: my-llm-proxy.example.com
protected_paths:
- messages.#.content.#.thinking
- messages.#.reasoning_contentrules.blocklist— extra regex patterns. Matched strings are added to the vault and replaced with placeholders.rules.allowlist— patterns the daemon will never mask, even ifblocklistor defaults would match. Useful for public keys or known-safe identifiers.rules.disable_default— turn off the built-in patterns entirely (only yourblocklistis active).vendor_schemas— JSON paths in responses to leave untouched (e.g., signed thinking blocks, encrypted reasoning chunks). Paths use GJSON syntax;#indexes arrays. The host must also be inproxy-whitelist.txtto be intercepted. Built-ins already cover Anthropic, DeepSeek, and Moonshot.
Commands
clawise daemon startclawise daemon status --ca-path— print the CA cert path
See the CLI reference for full flags and config.