Skip to main content
CybersecurityVulnerability Management

Docker Sandbox Flaw Exposes AI API Keys to Malicious Updates

Blurred monitor screen on a virtual machine surrounded by generic development tools.
CVE-2026-136998 is a vulnerability in Docker Sandboxes that can allow malicious kit updates to exfiltrate developers’ API keys without prompting or clear logging.

How the leak happens

The flaw stems from how Docker Sandboxes records and reuses credential approvals and from missing destination checks. When a developer first approves a third‑party kit, Docker records which domains may receive the approved API key. On later runs, however, the product’s check is incomplete: it verifies only that the developer approved the AI service, not that the destination remains one of the originally approved domains.

If an attacker distributes an updated kit that changes the destination to a host the attacker controls, Docker’s proxy will inject and send the real API key along with the request without prompting the developer. The policy log will simply record that the connection was allowed and will not indicate that a credential was injected.

As application security company Endor Labs summarized, “The second ‘sbx create’ shows no prompt. ‘sbx policy log’ records the connection to the canary host as allowed and says nothing about a credential being injected into it.”

Services and artifacts affected

Endor Labs’ researcher Payton Kennedy reported the finding and demonstrated the issue using a dummy Anthropic key. Kennedy identified that the vulnerable credential‑handling code is shared across 13 built‑in services: Anthropic, Copilot, Cursor, Devin, Droid, GitHub, Google, Groq, Mistral, Nebius, OpenAI, OpenRouter, and xAI.

The faulty code that created this vector was introduced in Docker Sandboxes version 0.43.0, according to the researcher’s disclosure.

Timeline and the fix

Kennedy disclosed the vulnerability to the Docker project. Docker pushed a fix in Docker Sandboxes version 0.55.0, which was released on November 30. The updated release changes how kit credential injection is handled: it now respects the destinations approved separately for API keys and for OAuth in credential bindings, and it treats bindings that have no approved destinations as missing.

The vulnerability has been tracked as CVE-2026-136998.

Immediate risks: account charges and repository access

The practical consequences depend on the credential type. A stolen AI provider API key could be used to consume paid API calls and thereby incur charges to the victim’s account. A stolen GitHub token, if its scope permits, could grant access to repositories. Because the behavior can occur without additional prompts and because logs can appear to show only permitted connections, operators reviewing policy logs could reasonably miss evidence that keys were sent to an attacker‑controlled host.

What this means for developers, security teams, and operators

  • Developers: Upgrade to Docker Sandboxes 0.55.0 to receive the fix, and review any credential approvals you have previously granted to third‑party kits. If a kit shows suspicious configuration or destination changes, rotate the potentially exposed key “out of an abundance of caution,” as recommended in the advisory.
  • Security teams and operators: Recognize that policy logs may record only that a connection was allowed and might not reflect whether a credential was injected. Where feasible, verify approved destination lists for credential bindings and treat bindings with no approved destinations as missing or invalid. Consider auditing recent kit updates and any unusual destination changes.
  • Procurement and platform owners: If your teams rely on prebuilt kits that integrate with AI or source control providers, confirm that those kits run on Docker Sandboxes versions with the fix and that credential‑binding policies are narrowly scoped to explicit destinations.

Conclusion

CVE-2026-136998 exposed a subtle but practical gap: credential approvals tied to a service, rather than to explicit destinations, can be abused by a malicious kit update. Docker’s November 30 release of version 0.55.0 changes how credential destinations are enforced, but the advisory underscores two recurring operational truths—credential approvals should be narrow, and rotations are the safest response when a trusted runtime shows a systemic flaw. Users are advised to upgrade, inspect prior approvals, and rotate keys where configuration drift or unexpected destination changes are observed.

Original reporting: https://www.bleepingcomputer.com/news/security/docker-sandboxes-bug-could-leak-ai-api-keys-via-malicious-updates/