High severity · published Mar 20, 2025
CVE-2024-6825
Remote Code Execution in BerriAI/litellm
8.8
CVSS
1.6%
EPSS
No
On KEV
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 vector
CVSS:3.0/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Attack vector
Network
Complexity
Low
Privileges
Low
User interaction
None
Confidentiality
High
Integrity
High
Availability
High
Scope
Unchanged
Exploitation
Is it being used?
Exploit prediction (EPSS)1.6% · higher than 76% of CVEs
Exploited in the wildNo evidence yet
CISA KEVNot listed
Ransomware campaign useNot known
Affected products
Which versions
BE
berriai/litellm · berriai
before v1.65.4.dev6 · source: vendor
LI
Litellm · Litellm
before 1.65.4; 1.65.4 · source: NVD
References
NVD
https://nvd.nist.gov/vuln/detail/CVE-2024-6825
CVE.org
https://www.cve.org/CVERecord?id=CVE-2024-6825
github.com
https://github.com/berriai/litellm/commit/441c7275ed2715f47650a7c2e525055c804073a9
Exploit
https://huntr.com/bounties/1d98bebb-6cf4-46c9-87c3-d3b1972973b5
More from berriai/litellm
9.8
CVE-2024-5751
Remote Code Execution in BerriAI/litellm
9.8
CVE-2024-4264
Remote Code Execution in berriai/litellm
9.8
CVE-2024-2952
Server-Side Template Injection in BerriAI/litellm
8.1
CVE-2025-0628
Improper Authorization in BerriAI/litellm
8.1
CVE-2024-4888
Arbitrary File Deletion in BerriAI/litellm
