Home › Intelligence › Brief
VULNERABILITY BRIEF🔴 Critical Vulnerability

Critical Remote Code Execution in BerriAI LiteLLM (CVE‑2026‑40217) via Unprotected Alternate Channel

BerriAI LiteLLM’s `/guardrails/test_custom_code` endpoint allows unauthenticated attackers to rewrite bytecode and execute arbitrary code, earning a CVSS 9.8 rating and placement on CISA’s KEV list. The flaw highlights the need for robust application‑runtime controls and evidence‑ready remediation processes.

LiveThreat™ Intelligence · 📅 November 23, 2026· 📰 nvd.nist.gov
🔴
Severity
Critical
VU
Type
Vulnerability
🎯
Confidence
High
🏢
Affected
1 sector(s)
✅
Actions
3 recommended
📰
Source
nvd.nist.gov

Critical Remote Code Execution in BerriAI LiteLLM (CVE‑2026‑40217) via Unprotected Alternate Channel

What It Is — BerriAI LiteLLM, a lightweight library that enables developers to integrate large‑language‑model (LLM) capabilities into applications, contains an unprotected alternate‑channel flaw (CVE‑2026‑40217). The vulnerability resides in the /guardrails/test_custom_code URI, an endpoint intended for internal testing of custom guardrail logic. Because the endpoint does not enforce authentication or integrity checks, a remote attacker can submit crafted bytecode that the library rewrites and executes. Successful exploitation yields full remote code execution (RCE) on any host running the vulnerable version of LiteLLM, with the attacker gaining the same privileges as the process that loads the library.

The flaw was added in a recent release that introduced a “custom guardrails” feature. The code path bypasses the normal sandbox that protects user‑supplied prompts, treating the supplied bytecode as trusted. No input validation or signature verification is performed, and the endpoint is exposed on the default HTTP server without TLS.

CISA added the issue to its Known Exploited Vulnerabilities (KEV) catalog on 12 Oct 2026, flagging it as a high‑impact vulnerability that is actively exploited in the wild. The National Vulnerability Database (NVD) assigns a CVSS v3.1 base score of 9.8 (Critical), citing network‑accessible RCE, no authentication, and complete system compromise.

Affected Products — BerriAI LiteLLM library, all versions 1.4.0 through 1.4.5 (the exact range disclosed by the vendor). The vulnerability is present regardless of the host language (Python, Node, etc.) because the underlying bytecode interpreter is shared across bindings.

Why It Matters for Trust & Control Assurance — This incident tests the control objective of secure software development and runtime integrity—ensuring that code execution paths are protected, that testing interfaces are not exposed in production, and that changes to executable artifacts are auditable.

Recommended Actions

  • Patch Immediately – Apply the vendor‑released fix (LiteLLM 1.4.6) that removes the /guardrails/test_custom_code endpoint from production builds.
  • Disable the Endpoint – If upgrading is not feasible, block the URI at the web‑application firewall or reverse‑proxy level and enforce TLS.
  • Review CI/CD Pipelines – Add a step that scans for exposed test endpoints and validates that only signed, production‑ready bytecode is deployed.
  • Implement Runtime Monitoring – Enable detailed logging of all requests to LiteLLM endpoints; alert on any access to /guardrails/* paths.
  • Conduct a Post‑Remediation Audit – Verify that the patch is applied across all environments, and capture evidence of the change for audit readiness.
  • Update Threat Models – Reflect the new attack surface (unauthenticated code‑execution channels) in your application threat model and risk register.

Source: CISA KEV – CVE‑2026‑40217

📰 Original Source
https://nvd.nist.gov/vuln/detail/CVE-2026-40217 ↗

This LiveThreat Intelligence Brief is an independent analysis. Read the original reporting at the link above.

From the Verisq platform · Trust Operations

Misconfigurations are control gaps in disguise.

Verisq AI Trust Operations turns findings like this into mapped controls with continuous evidence, keeping your audit readiness current instead of point-in-time.

Map your controls with Verisq AI Trust Operations →