Do not file secrets, tokens, or private paths in GitHub issues.
To report a vulnerability, use GitHub Security Advisories for this repository.
The admin bearer belongs to the owner CLI, dashboard and coordinator MCP host,
not workers. Local hub workers receive a session-bound abw_ bearer; only its
SHA-256 hash and session binding are retained by the hub's credential registry,
in RAM. Tokens are registered for redaction and never persisted in Bridge state.
A worker bearer is accepted only during an active turn of its bound session. Resident ACP processes reuse it across turns; it is inactive between turns and permanently revoked on process exit, session closure or hub shutdown. A leaked resident-process token can become usable again during that process's next turn. One-shot workers receive fresh tokens each turn, revoked when the turn ends.
Workers may discover agents, dispatch/invoke peers, and read/wait/cancel their
own child tasks and read child-session transcripts. They cannot manage approvals,
preferences, remote settings, UI login, or sessions. Follow-ups and transcripts
are restricted to sessions containing only their own child tasks. Caller identity,
notification destination and depth come from the token binding, never the
X-Agent-Bridge-Caller header. Admin requests have no caller identity, so cannot
request notify_caller. Notification turns retain their no-notification-loop rule.
Remote-origin workers still receive no hub credential (AGENT_BRIDGE_HUB=off).
This is an API authorization boundary, not an OS sandbox. Same-user code may still access the owner's keyring or other local credentials; isolate untrusted workers with a separate OS account or container.
The management API is loopback-only, with no --allow-remote escape hatch.
Discovery sends credentials only to HTTP loopback URLs or HTTPS URLs; URLs
with embedded credentials, query strings or fragments are rejected.
Never tunnel the admin listener; only the separate gateway may be exposed.
Remote calls require local approval by default. Enabling the gateway rejects
allowlisted agents with permission-skipping argv/presets (including the bundled
Claude/OpenCode CLI presets) unless that agent explicitly sets
remote_allow_unsafe_permissions = true. This opt-in emits a warning and does
not create a sandbox. Same-user workers can read the owner's keyring; use a
separate OS user or container for remote-origin execution.
The bundled DSH preset also needs this opt-in: its DSH_PERMISSION_MODE
environment setting disables tool approvals in the legacy ACP composition.
CLI prompts use stdin or a standalone positional argument after --; custom
unprotected {prompt} templates are rejected. Model/effort selections are
restricted to 1–100 characters matching
^[A-Za-z0-9._:/@][A-Za-z0-9._:/@-]{0,99}$ for effort; model IDs also allow
non-leading # for MiniMax variants and \ for ZCode provider/model IDs. Remote callers additionally need
the exact selection in the agent's remote_allowed_models or
remote_allowed_efforts list (empty by default). These guards prevent option
injection; they do not constrain what tools an agent can execute.
Callbacks require public HTTPS destinations. DNS is validated at dispatch and
each send; all addresses must pass checks and the connection uses a validated IP
with the original Host/TLS SNI and certificate verification. No redirects/proxies.
hub.allow_insecure_callbacks = true additionally permits loopback HTTP/HTTPS,
not other private networks. Receivers verify HMAC-SHA256 over UTF-8
timestamp.task_id. followed by exact body bytes, using X-Agent-Bridge-Timestamp,
X-Agent-Bridge-Task and X-Agent-Bridge-Signature (sha256=HEX); reject >300s skew
and deduplicate task IDs to resist replay. This changes the previous body-only signature.
require_cf_access has been removed and is rejected in configuration. Header
presence does not authenticate a JWT. Enforce Cloudflare Access service-token
authentication at the edge, with no direct-origin bypass; the hub does not verify JWTs.
Callback signing secrets are passed by keyring reference (callback_secret_name),
never as REST/MCP/call values. agent-bridge callback-secret set NAME prompts
securely; list prints names only and delete NAME removes the entry.
ask --callback-secret creates a short-lived keyring reference and cleans it up
after dispatch; it refuses memory-only storage that another process cannot read.
Signing secrets require at least 32 characters. Tasks keep only a signed boolean.
Named callback signing keys are admin-only; worker bearers cannot request a
callback signed with an owner's keyring entry.
Named-key lookups read the keyring authoritatively and fail closed if unavailable;
cached values do not survive external deletion. Per-task delivery secrets retain
their documented RAM-only fallback.
Remote gateway tokens expire after 3600 seconds by default, independent of cloud
turn timeouts (hub.remote.token_ttl_sec overrides this). The token is included
in the cloud prompt and remains in provider-side session history; protect that
history as credential-bearing data. Bridge redaction cannot remove provider copies.
Both listeners disable Uvicorn access logging, including query strings. The
purpose-built gateway audit remains redacted. Behind a tunnel, remote_ip is
typically the tunnel process's loopback address, not the original client.
CF-Connecting-IP and other forwarded headers can be spoofed without trusted
Access edge validation and a non-bypassable origin. Treat these fields as advisory,
never as authentication or reliable attribution.
agent-bridge ui passes its login URL to a browser process: the one-time code
can be visible in process arguments until consumed or expired (60 seconds).
The fragment is cleared by the page and is not the admin bearer. --no-open
avoids launching a browser with that argument, but still prints a sensitive link;
do not save/share it. This flow cannot protect against same-user process inspection.