Impact
The flaw is caused by insufficient input validation in the preview endpoints /mcp-rest/test/connection and /mcp-rest/test/tools/list. When a client supplies a full server configuration that uses the stdio transport, the proxy attempts to connect and spawns a subprocess with the supplied command, arguments, and environment variables. Because the command is executed with the privileges of the proxy process, an attacker can run arbitrary code on the host. This is a classic command‑injection weakness (CWE‑77, CWE‑78) that can compromise confidentiality, integrity, and availability.
Affected Systems
The issue affects BerriAI’s LiteLLM AI gateway, from version 1.74.2 up to the pre‑1.83.7 stable release. Any installation that exposes the two preview endpoints to users with an API key is vulnerable. Versions 1.83.7 and newer contain the fix.
Risk and Exploitability
The vulnerability is only reachable to users who possess a valid proxy API key, with no role or privilege check performed. The EPSS score of 75% indicates a high likelihood of exploitation, and the listing in the CISA KEV catalog confirms active exploitation. The CVSS score of 8.7 classifies it as high severity. An attacker can choose any command and run it with the proxy process's privileges, enabling potential lateral movement, credential theft, or full host takeover. The likely attack vector is through authenticated API key usage on these preview endpoints.
OpenCVE Enrichment
Github GHSA