Read the docs
TI-2024-04849 Aliases CVE-2024-5225GHSA-h6m6-jj8v-94jj

SQL Injection in berriai/litellm

Priority HIGH 67CWE-89Published · Updated

Key facts

Attack vector
Network
Privileges required
High
User interaction
None
Attack complexity
Low
Impact type
SQL injection
Confidentiality · integrity · availability
High · High · High
Fix status
Fixed

Attack profile from CVSS 3.1 · NVD. Fix status from CNA and GitHub. Impact type from CWE-89.

Summary

An SQL Injection vulnerability exists in the berriai/litellm repository, specifically within the `/global/spend/logs` endpoint. The vulnerability arises due to improper neutralization of special elements used in an SQL command. The affected code constructs an SQL query by concatenating an unvalidated `api_key` parameter directly into the query, making it susceptible to SQL Injection if the `api_key` contains malicious data. This issue affects the latest version of the repository. Successful exploitation of this vulnerability could lead to unauthorized access, data manipulation, exposure of confidential information, and denial of service (DoS).

Why it matters now

Exploitation Proof of concept CISA SSVC · not in CISA KEV
EPSS 0.00429 37th percentileScored 2026-11-07
Public exploit Yes 1 exploit referenceTagged by NVD
Fix Fixed litellm (PyPI): 1.40.0

SSVC decision points

CISA ADP · SSVC 2.0.3

Exploitation
Poc
Automatable
No
Technical impact
Total

The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.

Affected products

VendorProductAffected versionsFixed inStatusSource
BerriAIberriai/litellmup to latest—No fix listedCNA
—litellm (PyPI)before 1.40.01.40.0Patch availableGHSA-h6m6-jj8v-94jj
  • berriai/litellm VendorBerriAI Affected up to latest Fixed in — No fix listed CNA
  • litellm (PyPI) Vendor— Affected before 1.40.0 Fixed in 1.40.0 Patch available GHSA-h6m6-jj8v-94jj

CPE configurations NVD · 1

CPEVersionsRoleVendor
cpe:2.3:a:litellm:litellm:*:*:*:*:*:*:*:*up to 1.40.2VulnerableBerriAI
  • cpe:2.3:a:litellm:litellm:*:*:*:*:*:*:*:* Versions up to 1.40.2 Vulnerable ·BerriAI

Remediation

  • Fix · GHSA-h6m6-jj8v-94jj litellm (PyPI) Fixed in 1.40.0 Advisory →

Timeline

  1. 2026-10-02 Threatist record created from CVE-2024-5225
  2. 2026-10-03 Alias added: GHSA-h6m6-jj8v-94jj

References

  • TI-2026-26015 Trivy ecosystem supply chain briefly compromised KEVCVSS 4.0CRITICAL 9.4
  • TI-2026-30529 LiteLLM: SQL injection in Proxy API key verification KEVCVSS 4.0CRITICAL 9.3
  • TI-2026-30582 LiteLLM: Authenticated command execution via MCP stdio test endpoints KEVCVSS 4.0HIGH 8.7
  • TI-2026-42639 LiteLLM: MCP Authentication Bypass via OAuth2 Passthrough Fallback KEVCVSS 4.0HIGH 8.8
  • TI-2024-05340 Remote Code Execution in BerriAI/litellm CVSS 3.1CRITICAL 9.8
  • TI-2024-02760 Server-Side Template Injection in BerriAI/litellm CVSS 3.0CRITICAL 9.8
See all 36 →

Sources