CVE-2024-6825: Remote Code Execution in BerriAI/litellm
Vulnerability summary
CVE-2024-6825 is a high (CVSS 8.8) Improper Control of Generation of Code vulnerability in berriai berriai/litellm. EPSS estimates a 1.64% chance of exploitation in the next 30 days, higher than 77.1% of scored vulnerabilities. 1 public exploit is recorded.
Public exploit (reference, Date unknown)
Source freshness unavailable
How is this decided?Timeline
- 20-03-2025PublishedVulnerability first disclosed.
- 15-10-2025Last modifiedVulnerability information updated.
Description
BerriAI/litellm version 1.40.12 contains a vulnerability that allows remote code execution. The issue exists in the handling of the 'post_call_rules' configuration, where a callback function can be added. The provided value is split at the final '.' mark, with the last part considered the function name and the remaining part appended with the '.py' extension and imported. This allows an attacker to set a system method, such as 'os.system', as a callback, enabling the execution of arbitrary commands when a chat response is processed.
CVSS metrics
3 scores · 3 sources · 1 version- OSV · PypiEcosystem advisory · calculated8.8HighCVSS:3.0/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
- NVDNIST8.8HighCVSS:3.0/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
EPSS trend
Probability
1.64%
Chance of exploitation in the next 30 days
Percentile
77%
Versus all other CVEs
30-day change
Decrease -0.01 pp
From 1.65% on 04-11-2026
Known exploited
Compare KEV catalogsNot in the CISA KEV catalog.
Not in the ENISA CNW catalog.
Not in the CIRCL catalog.
Public exploits
1 foundExploit Reference (huntr.com)
Maturity: unknown
Weaknesses
CWE · root causeAffected systems
Known conditions: network-reachable, low-privilege account, no user interaction (CVSS vector). Other conditions: not stated in public data.
Berriai1 product
- berriai/litellm≥ unspecified, < v1.65.4.dev6
Litellm1 product
- litellm< 1.65.4 | 1.65.4:dev2
PyPI1 product
- litellm≥ 1.40.3.dev2, ≤ 1.40.12
3 vendors · 3 products
References
7 links- github.com/BerriAI/litellmPACKAGE
- pypi.org/project/litellmPACKAGE