Cyber Posture

CVE-2026-40217

HighPublic PoCUpdated

Published: 10 April 2026

Published
10 April 2026
Modified
27 April 2026
KEV Added
Patch
CVSS Score 8.8 CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
EPSS Score 0.0028 51.1th percentile
Risk Priority 18 60% EPSS · 20% KEV · 20% CVSS

Summary

CVE-2026-40217 is a high-severity Unprotected Alternate Channel (CWE-420) vulnerability in Litellm Litellm. Its CVSS base score is 8.8 (High).

Operationally, exploitation aligns with the MITRE ATT&CK technique Exploit Public-Facing Application (T1190); ranked in the top 48.9% of CVEs by exploit likelihood; it is not currently listed in the CISA KEV catalog; a public proof-of-concept is referenced.

The strongest mitigations our analysis identified are NIST 800-53 CM-7 (Least Functionality) and SI-10 (Information Input Validation).

Threat & Defense at a Glance

What attackers do: exploitation maps to Exploit Public-Facing Application (T1190). What defenders deploy: see the NIST 800-53 controls recommended below.
Threat & Defense Details

Mitigating Controls (NIST 800-53 r5)AI

prevent

Directly remediates the bytecode rewriting vulnerability in LiteLLM by applying patches or upgrades as recommended in the x41-dsec advisory.

prevent

Prevents exploitation by configuring LiteLLM to disable the unnecessary /guardrails/test_custom_code URI and other non-essential functions.

prevent

Blocks arbitrary code execution by validating and sanitizing all inputs submitted to the /guardrails/test_custom_code endpoint to prevent bytecode rewriting.

MITRE ATT&CK Enterprise TechniquesAI

T1190 Exploit Public-Facing Application Initial Access
Adversaries may attempt to exploit a weakness in an Internet-facing host or system to initially access a network.
Why these techniques?

The vulnerability allows remote code execution via a specific URI in LiteLLM, a network-exposed service, directly mapping to exploitation of public-facing applications.

Confidence: HIGH · MITRE ATT&CK Enterprise v19.0

NVD Description

LiteLLM through 2026-04-08 allows remote attackers to execute arbitrary code via bytecode rewriting at the /guardrails/test_custom_code URI.

Deeper analysisAI

CVE-2026-40217 is a critical vulnerability in LiteLLM versions through 2026-04-08 that enables remote attackers to execute arbitrary code through bytecode rewriting at the /guardrails/test_custom_code URI. Classified under CWE-420, it carries a CVSS v3.1 base score of 8.8 (AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H), indicating high severity due to its potential for significant impact across confidentiality, integrity, and availability.

The vulnerability can be exploited by remote attackers with low privileges over the network, requiring low attack complexity and no user interaction. Successful exploitation grants attackers the ability to execute arbitrary code on the affected system, potentially leading to full compromise including data theft, modification, or disruption of services.

The primary advisory from x41-dsec, available at https://www.x41-dsec.de/lab/advisories/x41-2026-001-litellm/, provides further details on the issue. Security practitioners should consult this reference for recommended mitigations and patches.

Details

CWE(s)

Affected Products

litellm
litellm
≤ 2026-04-08

CVEs Like This One

CVE-2026-35030Same product: Litellm Litellm
CVE-2026-42208Same product: Litellm Litellm
CVE-2026-42271Same product: Litellm Litellm
CVE-2026-35029Same product: Litellm Litellm
CVE-2024-9606Same product: Litellm Litellm
CVE-2025-54309Shared CWE-420
CVE-2025-67303Shared CWE-420
CVE-2025-13315Shared CWE-420
CVE-2025-41727Shared CWE-420
CVE-2026-33634Same product: Litellm Litellm

References