LiteLLM - RCE (CVE-2026-40217)
Description
LiteLLM through 2026-04-08 allows remote attackers to execute arbitrary code via bytecode rewriting at the /guardrails/test_custom_code URI.
psychologyCrowdSec Analysis
CVE-2026-40217 is a high-severity remote code execution vulnerability in BerriAI LiteLLM, affecting versions through 2026-04-08. An attacker with low-level privileges can exploit bytecode rewriting at the /guardrails/test_custom_code endpoint to execute arbitrary code, potentially compromising the confidentiality, integrity, and availability of the affected system.
CrowdSec has been tracking this vulnerability and its exploits since 19th of November 2026.
CrowdSec has not observed any significant exploitation activity targeting CVE-2026-40217 across its network. As a result, no community-driven trend analysis is available for this vulnerability at this time.
Attackers target the POST /guardrails/test_custom_code endpoint with a crafted JSON custom_code Python payload to escape the guardrail sandbox and execute commands. Exploitation attempts may include a bearer token in the Authorization header.
Full Intelligence Available
Connect your API key to access CrowdSec scores, exploit timelines, and attacker IPs.
| Event | Date |
|---|---|
| CVE Published | 2026-04-10 |
| CISA KEV | 2026-11-18 |
| Rule Released | 2026-11-19 |
| CrowdSec First Seen | 2026-11-26 |
| CISA Remediation Deadline | 2026-12-02 |