(0Day) LiteLLM MCP Command Injection Remote Code Execution Vulnerability
Vulnerability Details
This vulnerability allows remote attackers to execute arbitrary code on affected installations of LiteLLM. Authentication is required to exploit this vulnerability.
The specific flaw exists within the handling of MCP stdio configurations. The issue results from the lack of proper validation of a user-supplied string before using it to execute a system call. An attacker can leverage this vulnerability to execute code in the context of the service account.
Additional Details
06/17/26 - ZDI reported the vulnerability to the vendor
07/03/26 - ZDI asked for updates
08/28/26 - ZDI asked for updates
09/15/26 - the vendor closed the report as a false positive
10/26/26 - ZDI disputed the vendor's closure as the existing fix was incomplete
10/29/26 - the vendor reopened the report agreeing the mitigation wasn't enough
10/30/26 - ZDI asked for the fix plan
11/04/26 - ZDI notified the vendor of the intention to publish the case as a 0-day advisory on 11/18/26
11/13/26 - the vendor stated it planned to ship a fix and issue a GHSA before the 11/18 deadline
11/16/26 - ZDI asked the vendor to confirm whether the fix/GHSA had shipped
11/17/26 - the vendor clarified no separate patch is coming, and disputed that the report describes a vulnerability
11/17/26 - ZDI confirmed the zero-day advisory would publish on 11/18/26
-- Mitigation: The vendor recommends the following mitigation:
Stdio MCP servers run admin-chosen host commands; only proxy admins can create or test them. The CVE-2026-42271 allowlist doesn’t limit what admins can run, isn’t a security control, and will be removed.
From v1.104.0, stdio servers are disabled unless LITELLM_ENABLE_MCP_STDIO=true is set in env (not via API/config/DB); to stay safe, upgrade to 1.104.0+ and leave unset.
Always replace any default/example master key with a strong random value; v1.104.0+ blocks startup if unset, empty, or sk-1234.
Disclosure Timeline
- 2026-06-17 - Vulnerability reported to vendor
- 2026-11-18 - Coordinated public release of advisory
- 2026-11-18 - Advisory Updated
Credit
David Fiser and Alfredo Oliveira of TrendAI Research