A LiteLLM sandbox escape patched since May is now under active attack
CISA adds CVE-2026-40217 to its exploited list: a bytecode-level escape from the LLM gateway's custom-code guardrail sandbox, fixed in 1.83.10.
CISA added CVE-2026-40217 to its Known Exploited Vulnerabilities catalogue on 18 November, confirming active exploitation of a sandbox escape in LiteLLM, the open-source LLM gateway.
The bug sits in the POST /guardrails/test_custom_code endpoint, which runs user-supplied Python inside a hand-rolled sandbox so admins can test custom guardrail code. That sandbox can be escaped with bytecode-level techniques, giving arbitrary code execution inside the proxy process, which in default Docker deployments typically runs as root. Reaching the endpoint needs a proxy-admin credential, and CVSS rates it 8.8. The flaw affects versions 1.81.8 through 1.83.9 and was fixed in 1.83.10, released back in May. Federal agencies now have until 2 December to remediate under CISA’s directive.
Why it matters: if you run a self-hosted LiteLLM proxy and haven’t checked your version since the spring, do it now. A six-month-old patch sitting unapplied is exactly the gap attackers wait for, and a compromised proxy sees every API key and prompt passing through it.
The caveat: exploitation requires a proxy-admin credential first, so this isn’t exposed to anonymous internet scanning the way an unauthenticated RCE would be. CISA hasn’t said how attackers are obtaining that access.