You Approved the Domain, Docker Remembered the Name: CVE-2026-136998 Shows AI Agent Consent Prompts Can Outlive What You Approved

You Approved the Domain, Docker Remembered the Name: CVE-2026-136998 Shows AI Agent Consent Prompts Can Outlive What You Approved
A Docker Sandboxes flaw let an updated AI agent kit quietly send your real API key to a new server, because the approval you gave was stored but never enforced, and that weakness reaches well beyond one tool.
What happened
Docker Sandboxes (the sbx CLI and its sandboxd daemon) is Docker's answer to a real problem: developers want to let AI coding agents run freely, but they don't want those agents holding their Anthropic, OpenAI or GitHub keys. The design is sensible. You store the real key on the host with sbx secret set. Inside the sandbox the agent only sees a placeholder such as x-api-key: proxy-managed. A proxy on the host swaps the placeholder for the real key, but only for requests going to approved destinations.
Agents are packaged as "kits", and third-party kits can be pulled by tag, branch or directory. Each kit declares, per service, which domains should receive the key. In v0.43.0 Docker added a consent gate. When you run sbx create, it shows each credential and the domains it will go to. If you approve, a binding is written to ~/.config/sbx/credentials.yaml.
On 30 November 2026 Docker released v0.55.0. Its release notes list a fix for CVE-2026-136998, "where a modified third-party kit could reuse a previously approved service binding". The researcher who reported it says the binding's list of approved domains was written to disk but never read. At request time the proxy only checked one thing: was there a binding for this service name? If there was a row for "anthropic", the real key was injected into requests to whatever domains the current kit declared.
The attack, step by step
The researcher reported the issue to Docker on 21 September 2026 and later published the steps:
- An attacker publishes kit v1. Its inject block names only
api.anthropic.com, so the consent prompt is accurate and harmless. - The developer reads the prompt, approves, and the binding is saved.
- The attacker updates the kit at the same reference and changes only the inject domain to a server they control. The kit can also add that host to its own network allowlist.
- On the next
sbx createthe gate finds the existing "anthropic" binding and passes. There is no new prompt, no warning and no diff. - The proxy puts the real key into requests to the attacker's host. In the researcher's test the key went out in cleartext over plain HTTP, and the sandbox's policy log showed the connection as allowed with no mention that a credential had been injected.
The researcher tested only the Anthropic service, using a dummy key, but says all 13 built-in services share the same injection path, including OpenAI, GitHub, Copilot, Google, Mistral and xAI. Their scoring is CVSS 3.1 8.2 (High). They first rated it 9.3 with a network attack vector, then corrected it to local. Versions from 0.43.0 up to the fix are affected. Releases before 0.43.0 did not have the consent gate at all, so this particular flaw doesn't apply to them.
Why this matters more than one CVE
The striking detail is that the code apparently already contained a function, MissingDomainsForService, which matches the missing check, yet it did not gate the runtime path. The security model was designed and partly built, and the user interface promised it. The enforcement simply wasn't connected.
That is the general lesson. A consent prompt is a contract, and the contract is only as good as the code that enforces it at the moment of use. Docker's prompt told users "this key goes to these domains". Users made a sensible decision based on that. The system then enforced a much weaker rule: "this service is allowed".
It is also a supply-chain problem dressed up as an AI problem. Approving a kit by a mutable tag or branch is like approving a browser extension and then letting it auto-update with new permissions. Browser and mobile platforms learned years ago to re-prompt when an update asks for more. AI agent tooling is going through the same lessons much faster, and with something more valuable at stake: an API key with a credit card behind it. As earlier stolen-key incidents have shown, a leaked model key turns into a large bill within hours.
Note that the credential proxy did its main job. The agent inside the sandbox never saw the raw key. The leak happened outside the sandbox, in the trusted host component that decides where keys may go. As agent isolation improves, attackers will go after the policy layer around it: allowlists, bindings, approvals and the update path that changes them.
What Docker changed
According to the v0.55.0 release notes, credential injection now enforces approved destinations for both API keys and OAuth tokens, and a binding with no approved destinations is treated as missing. The same release adds related hardening:
- External endpoints used by local sandboxes must use HTTPS to receive host-managed API keys, and OAuth token exchanges over HTTP are rejected with HTTP 403.
- Custom secrets are only put into headers that were explicitly bound, and they must be at least eight characters long.
- Local sandboxes refuse workspace or mount paths that overlap Sandboxes' own config, state or credential folders, unless an override is set.
The release also has a breaking change: several DOCKER_SANDBOXES_* environment variables are no longer read, and the settings must be saved with sbx settings set. Check your scripts before upgrading CI runners.
Practical takeaways
For teams using Docker Sandboxes:
- Upgrade to v0.55.0 or later on every workstation and runner.
- Review
~/.config/sbx/credentials.yamland delete bindings granted to third-party kits you no longer use or don't fully trust. - If a third-party kit changed after you approved it, rotate the affected provider keys and check usage and billing logs for traffic you don't recognise.
- Pin kits to a fixed commit, or keep a reviewed local copy, instead of following a tag or branch.
- Scope keys to a single sandbox with
--sandboxrather than relying on the global default ofsbx secret set.
For anyone building or buying AI agent tooling:
- Ask vendors what an approval is bound to. A name is weak. A content digest plus the specific destinations is much better.
- Treat any change in where a credential goes as a new permission that needs a new prompt.
- Make sure credential injection is logged in its own right, not only as "connection allowed".
- Give agents spend-capped, project-scoped API keys, so that a leak costs a few dollars rather than a month's budget.
