Skip to content

CVE-2026-42271: BerriAI LiteLLM Command Injection Reaches CISA KEV — AI Infrastructure Under Attack

CISA added CVE-2026-42271 in BerriAI LiteLLM to the Known Exploited Vulnerabilities catalogue on 8 June, confirming active exploitation of a command injection vulnerability that allows API keys with limited privileges to execute arbitrary commands on the LiteLLM host. Organisations running LiteLLM as an AI gateway should update to v1.83.7-stable immediately.

Article software-development-security

CISA added CVE-2026-42271 to the Known Exploited Vulnerabilities catalogue on 8 June, confirming active exploitation of a command injection vulnerability in BerriAI LiteLLM — a widely deployed open-source proxy that provides a unified API interface across multiple large language model providers. The vulnerability allows an attacker with a low-privilege LiteLLM API key to inject operating system commands that execute on the LiteLLM host with the permissions of the LiteLLM process.

LiteLLM is used by organisations to manage API access to OpenAI, Anthropic, Google Gemini, Azure OpenAI, and other LLM providers through a single gateway. The deployment model — typically a containerised service with API keys distributed to multiple internal services and developers — creates a large key-holding population, any one of whom could exploit this vulnerability.

Vulnerability Details

CVE-2026-42271 is a command injection vulnerability in LiteLLM’s model management endpoint. LiteLLM includes an administrative interface for managing model configurations, API key budgets, and routing rules. A specific endpoint in this interface processes user-supplied input that is incorporated into a system command without sufficient sanitisation.

The critical aspect of this vulnerability is the privilege requirement: low-privilege API keys — the type distributed to individual developers and applications for LLM API access — are sufficient to reach the vulnerable endpoint. This means any developer or service with a LiteLLM API key can exploit this vulnerability, regardless of whether they have administrative access to the LiteLLM instance.

CVSS assessment: High severity. Network access vector, low complexity, low privileges required, no user interaction. Impact: full compromise of the LiteLLM host.

Affected versions: LiteLLM v1.83.6 and earlier. Patched version: LiteLLM v1.83.7-stable (released 3 June 2026).

Why AI Infrastructure Is Now a KEV Category

CVE-2026-42271 joins a growing list of KEV-confirmed vulnerabilities in AI infrastructure tooling. The pattern reflects a structural reality: AI tools are being adopted rapidly in enterprise environments, often by development and data science teams rather than through traditional IT security procurement processes. The security review that would apply to a new SIEM or endpoint agent — architecture review, penetration testing, vendor security questionnaire — is frequently not applied to AI gateways and LLM proxy services.

LiteLLM’s deployment pattern makes this worse: it is commonly deployed with broad API key distribution (many developers and services have keys), often on internal infrastructure that is assumed to be low-risk because it is not internet-facing (but is accessible from any compromised internal system), and often without the monitoring that would detect unusual command execution.

  • Update to LiteLLM v1.83.7-stable immediately: The patch is a point release available via pip install litellm==1.83.7 or by pulling the updated container image from the BerriAI registry.
  • Audit API key holders: Identify all parties (users, services, CI/CD pipelines) that hold LiteLLM API keys. Anyone with a key was potentially in scope to exploit this vulnerability.
  • Review LiteLLM logs for exploitation indicators: Check LiteLLM access logs for unusual requests to model management endpoints (/model/, /team/, /key/) from API keys that do not normally access these endpoints. Unexpected subprocess execution in LiteLLM process logs is a post-exploitation indicator.
  • Apply principle of least privilege to API keys: LiteLLM supports key-level permissions — production application API keys should not have administrative permissions. Use litellm_budget and model restriction settings to limit what each key can access.
  • Isolate LiteLLM from internal infrastructure: LiteLLM instances should not have outbound access to internal systems (Active Directory, internal APIs, databases) that are not required for LLM proxying. Network segmentation limits the blast radius if the host is compromised.

Broader Implication

CVE-2026-42271 is the second AI infrastructure component to reach the CISA KEV in 2026. The first was the Langflow AI workflow builder (CVE-2026-5027, also command injection). The recurrence is not coincidental — AI infrastructure tools are built on Python stacks that frequently use subprocess and eval patterns for extensibility, creating a class of command injection risk that is familiar in other contexts but is appearing in new products that have not undergone the security review cycle of more mature enterprise software.

Organisations deploying AI tooling at scale should apply the same security governance to AI infrastructure components — vulnerability management, periodic penetration testing, dependency scanning — that they apply to other production infrastructure software.

Share this article

Related Intelligence

💻 AppSec

The AI Infrastructure Security Deficit: Langflow, LiteLLM, and a Repeating Pattern

Two AI infrastructure components — Langflow and LiteLLM — have reached the CISA Known Exploited Vulnerabilities catalogue in June 2026, both with command injection vulnerabilities in Python-based AI tooling. The pattern reflects a systemic gap: AI infrastructure is being deployed in enterprise environments under procurement and security processes designed for end-user applications, not for server-side infrastructure with network-accessible APIs.

#ai-infrastructure +9
💻 AppSec

LiteLLM CVE-2026-42208 — SQL Injection in AI Gateway Proxy Added to CISA KEV

CVE-2026-42208, a SQL injection vulnerability in the LiteLLM AI gateway proxy, has been added to the CISA Known Exploited Vulnerabilities catalogue following confirmed exploitation. LiteLLM is widely deployed in enterprise environments as a unified API layer routing requests to multiple LLM providers (OpenAI, Anthropic, Azure OpenAI, Bedrock). Exploitation allows an attacker to read and modify the LiteLLM database, including API keys, user records, and model configuration. Update to LiteLLM 1.42.2 immediately.

#litellm +8
💻 AppSec

Langflow CVE-2026-5027 Exploitation Accelerates: AI Workflow Builder's Path Traversal RCE Under Active Attack

Exploitation of CVE-2026-5027 in Langflow, the AI workflow builder, has intensified following public PoC release. The path traversal remote code execution vulnerability, added to CISA's KEV on 8 June, is being used to deploy credential stealers and post-exploitation agents against organisations running unsecured Langflow instances. Upgrade to Langflow 1.3.5 immediately.

#langflow +9