Exploited now
Vulnerability WatchVulnerabilities, exploits & advisories — updated every 15 minutes
Alerts

Home › CVE › Linux

CVE-2026-42271 — BerriAI LiteLLM Command Injection Vulnerability

Actively exploited (CISA KEV)High · CVSS 8.7EPSS 7.3% First seen May 08, 2026
LinuxOperating systemsAIVulnerabilitiesEndpoint security

Research article

BerriAI LiteLLM Command Injection Vulnerability (CVE-2026-42271)

CVECVE-2026-42271
Vendor and productBerriAI litellm; Red Hat OpenShift AI 2.25; Red Hat OpenShift AI 3.3
PublishedNovember 18, 2026 01:25 UTC
Research cut-offNovember 18, 2026 01:15 UTC
Sources reviewed5: NVD record (last modified 2026-10-26); CISA KEV catalog; vendor advisory page (github.com); FIRST EPSS (2026-11-16); 1 news report

Executive summary

CVE-2026-42271 affects BerriAI LiteLLM versions >= 1.74.2 and < 1.83.7, with CVSS 3.1 base score 8.8 HIGH, scored by nvd@nist.gov [1]. The vulnerability allows authenticated users to execute arbitrary commands on the host, as confirmed by CISA [2]. Immediate mitigation includes applying the fix in version 1.83.7 [3].

Key points

  • CVE-2026-42271 allows authenticated users to execute arbitrary commands on the host [3].
  • The CVSS 3.1 base score is 8.8 HIGH, scored by nvd@nist.gov (Primary) [1].
  • The vulnerability affects BerriAI LiteLLM versions >= 1.74.2 and < 1.83.7 [1].
  • CISA has evidence of exploitation in the wild [2].
  • The fix is available in version 1.83.7 [3].

Vulnerability identification

CVE IDVendorProductCWECVSS 4.0CVSS 3.1PublishedLast ModifiedRecord Status
CVE-2026-42271BerriAIlitellmCWE-77, CWE-78CVSS 4.0 base score 8.7 HIGH, scored by security-advisories@github.com (Secondary)CVSS 3.1 base score 8.8 HIGH, scored by nvd@nist.gov (Primary)2026-05-08T04:16:212026-10-26T20:10:00Analyzed

Technical background

The sources do not describe the product's general functionality or architecture. The NVD lists it as an affected component in several products, including Red Hat OpenShift AI [1].

Vulnerability description

The flaw allows unauthorized command execution on the proxy host through two test endpoints. The endpoints attempt to connect using the provided configuration, which spawns a subprocess with the proxy process's privileges [3]. The vulnerability is classified under the CWE-78 category, which involves improper neutralization of special elements in an OS command [3].

Root cause analysis

The sources do not provide a detailed root cause analysis beyond the CWE classification. The vulnerability is described as a command injection flaw, allowing authenticated users to execute arbitrary commands on the host [3].

Technical mechanics

The sources describe that the endpoints accept a full configuration including command execution parameters. The endpoints are protected by a valid proxy API key but lack role-based access control, enabling exploitation by authenticated users [3].

Attack surface and exploitation prerequisites

According to the CVSS vector, the vulnerability requires network access (AV:N) and low privileges (PR:L), with no user interaction needed (UI:N). The attack can be executed remotely without requiring user action [1].

Exploitation scenarios and attack lifecycle

The sources describe that authenticated users, including those with low-privilege internal-user keys, can exploit the flaw. The vendor page names the two affected endpoints, POST /mcp-rest/test/connection and POST /mcp-rest/test/tools/list [3].

Impact analysis

The CVSS 3.1 vector indicates high impact on confidentiality (C:H), integrity (I:H), and availability (A:H). The flaw enables arbitrary command execution on the host [1].

Affected products and versions

ProductAffected VersionFixed Version
litellm>= 1.74.2, < 1.83.71.83.7
redhat openshift ai>= 2.25, < 2.25.82.25.8
redhat openshift ai>= 3.3, < 3.3.43.3.4
redhat openshift ai3.4not listed

Exploitation and threat intelligence status

CVE-2026-42271 is listed in CISA's Known Exploited Vulnerabilities catalog, with evidence of exploitation in the wild [2]. The EPSS score for this vulnerability is 0.9144 (91.44%) as of 2026-11-16 [5].

Indicators of compromise

The sources give no indicators of compromise.

Detection and exposure assessment

Check installed versions against the affected versions [1]. The SANS ISC diary reports scans that targeted both CVE-2026-42271 and CVE-2026-48710 alongside Starlette, whose versions before 1.0.1 do not validate the Host header [4].

Immediate mitigation

The vendor recommends applying the fix in version 1.83.7 [3]. Users who cannot upgrade immediately are advised to block the two test endpoints at their reverse proxy or API gateway [3].

Permanent remediation

The fixed version is 1.83.7, as listed in the NVD record [1]. The vendor advisory page confirms this as the fixed version [3].

Workarounds and compensating controls

The sources do not give any workarounds or compensating controls. General guidance includes patching Starlette to version 1.0.1 or later to fix the issue [4].

Validation and verification

Confirm the installed version after updating and ensure the fix is applied to all affected components.

Incident response

Review system logs for unusual command executions (general guidance, not from the reviewed sources).

Security hardening and prevention

General guidance includes reducing the attack surface; S4 says reducing attack surface is critical for mitigating the current surge in vulnerabilities [4].

Risk assessment

The CVSS 3.1 base score is 8.8 HIGH, scored by nvd@nist.gov (Primary) [1]. The EPSS score for this vulnerability is 0.9144 (91.44%) as of 2026-11-16 [5].

Conclusion

CVE-2026-42271 is a command injection vulnerability in BerriAI LiteLLM that allows authenticated users to execute arbitrary commands on the host. The fix is available in version 1.83.7. Defenders should apply the patch promptly and block the affected endpoints if an upgrade is not immediately possible.

Remediation checklist

  1. Apply the fix in version 1.83.7 [3].
  2. Block the two test endpoints at the reverse proxy or API gateway if an upgrade is not immediately possible [3].
  3. Patch Starlette to version 1.0.1 to address the related Host header issue reported alongside CVE-2026-42271 [4].
  4. Check installed versions against the affected versions [1].
  5. Review system logs for unusual command executions (general guidance, not from the reviewed sources).
  6. Isolating affected systems if exploitation is suspected is general guidance; the reviewed sources do not give it.
  7. Validate data components before assembling complex entities [4].

Evidence gaps

  • The sources do not describe the product's general functionality or architecture.
  • The sources do not provide a detailed root cause analysis beyond the CWE classification.
  • The sources do not describe the complete version range of affected products.
  • The sources do not give any indicators of compromise.
  • The sources do not mention any detection signatures or workarounds beyond general guidance.

References

  1. CVE-2026-42271 record. NIST National Vulnerability Database (NVD), 2026-10-26. https://nvd.nist.gov/vuln/detail/CVE-2026-42271. Accessed 2026-11-18. CVE record with CVSS scores, affected versions, and NVD CPE configurations
  2. Known Exploited Vulnerabilities Catalog: CVE-2026-42271. Cybersecurity and Infrastructure Security Agency (CISA), 2026-06-08. https://www.cisa.gov/known-exploited-vulnerabilities-catalog. Accessed 2026-11-18. CISA KEV listing and exploitation status
  3. Vendor advisory page (github.com). github.com. https://github.com/BerriAI/litellm/security/advisories/GHSA-v4p8-mg3p-g94g. Accessed 2026-11-18. Vendor advisory details on the vulnerability and fixed version
  4. Scans for LiteLLM/Starlette (CVE-2026-42271, CVE-2026-48710), (Mon, Nov 16th). SANS ISC, 2026-11-16. https://isc.sans.edu/diary/rss/33522. Accessed 2026-11-18. News report on exploitation attempts and related Starlette vulnerability
  5. EPSS score for CVE-2026-42271. FIRST, 2026-11-16. https://api.first.org/data/v1/epss?cve=CVE-2026-42271. Accessed 2026-11-18. EPSS score and threat assessment

Written with AI assistance from the 5 sources listed above, as of the research cut-off; each fact is cited to its source. Check the vendor's advisory before acting.

Summary

LiteLLM is a proxy server (AI Gateway) to call LLM APIs in OpenAI (or native) format. From version 1.74.2 to before version 1.83.7, two endpoints used to preview an MCP server before saving it — POST /mcp-rest/test/connection and POST /mcp-rest/test/tools/list — accepted a full server configuration in the request body, including the command, args, and env fields used by the stdio transport. When called with a stdio configuration, the endpoints attempted to connect, which spawned the supplied command as a subprocess on the proxy host with the privileges of the proxy process. The endpoints were gated only by a valid proxy API key, with no role check. Any authenticated user — including holders of low-privilege internal-user keys — could therefore run arbitrary commands on the host. This issue has been patched in version 1.83.7.

Description: NIST National Vulnerability Database (public domain)

Severity breakdown

High · 8.7 CVSS 4.0 base score from the CNA (github.com)

An attacker with a normal user account can exploit this over the network, without any user action, but only under specific conditions.

Attack from
the network (remotely)
Attack complexity
low (no special conditions)
Special conditions
only in some setups or conditions
Login needed
yes, a normal user account
User action needed
no
Impact
high on confidentiality, integrity and availability
Impact on other systems
high on confidentiality, none on integrity and availability

Vector CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:H/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X · CVSS 3.1 8.8 from NVD: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Weakness

  • CWE-77: Improper Neutralization of Special Elements used in a Command ('Command Injection')
  • CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')

Affected and fixed versions

ProductAffected versionsFixed in
BerriAI litellm>= 1.74.2, < 1.83.7—

From the vendor's CVE record; confirm with the vendor advisory before relying on a version number.

CISA KEV

Exploited in the wild

BerriAI LiteLLM contains a command injection vulnerability that could allow any authenticated user, including holders of low-privilege internal-user keys, to run arbitrary commands on the host.

Listed as
BerriAI LiteLLM Command Injection Vulnerability
Added to the catalog
June 08, 2026
Federal due date
June 22, 2026
Required action
Apply mitigations per vendor instructions, follow applicable BOD 22-01 guidance for cloud services, or discontinue use of the product if mitigations are unavailable.
Ransomware use
Not known

US federal agencies must fix catalog entries by the due date; everyone else should treat them as a priority. CISA catalog entry

References by type

Patches and fixed releases

Other references

Details from NVD (public domain), CISA KEV (CC0).

Affected

  • BerriAI litellm
  • Red Hat OpenShift AI 2.25
  • Red Hat OpenShift AI 3.3
  • Red Hat OpenShift AI 3.4
  • Red Hat Exploit Intelligence

Frequently asked questions

What is CVE-2026-42271?

CVE-2026-42271 affects BerriAI LiteLLM versions >= 1.74.2 and < 1.83.7, with CVSS 3.1 base score 8.8 HIGH, scored by nvd@nist.gov. The vulnerability allows authenticated users to execute arbitrary commands on the host, as confirmed by CISA. Immediate mitigation includes applying the fix in version 1.83.7. Weakness type: Improper Neutralization of Special Elements used in a Command ('Command Injection') (CWE-77).

How severe is CVE-2026-42271?

CVE-2026-42271 has a CVSS 4.0 base score of 8.7 (high), from the CNA (github.com). An attacker with a normal user account can exploit this over the network, without any user action, but only under specific conditions.

Is CVE-2026-42271 being exploited?

Yes. CISA lists CVE-2026-42271 in its Known Exploited Vulnerabilities (KEV) catalog, added June 8, 2026: it has been exploited in real attacks. US federal agencies must fix it by June 22, 2026.

Which versions are affected by CVE-2026-42271?

BerriAI litellm >= 1.74.2, < 1.83.7.

How do I fix CVE-2026-42271?

Apply the fix in version 1.83.7. Block the two test endpoints at the reverse proxy or API gateway if an upgrade is not immediately possible. Patch Starlette to version 1.0.1 to address the related Host header issue reported alongside CVE-2026-42271.

Timeline & sources

References

Related vulnerabilities & news