CVE-2026-12774: BerriAI LiteLLM SSRF in MCP Server Connection Testing

CVE-2026-12774 · Severity: medium · CVSS 6.3 · Published 2026-06-21

LiteLLM is a tool used to manage and connect various AI models through a single interface. A security flaw in its Model Context Protocol (MCP) server testing component allows an attacker with a valid API key to force the server to send unauthorized requests to internal or external network locations. This could be used to scan internal company networks, bypass firewalls, or leak sensitive credentials to an attacker-controlled server.

Technologies: Berriai LiteLLM. Vendors: Berriai.

Quick answers

Is CVE-2026-12774 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2026-12774 being exploited in the wild.
How severe is CVE-2026-12774?
Medium severity, with a CVSS score of 6.3, published 21 June 2026.
Which products and versions are affected?
Berriai LiteLLM <= 1.82.2.
Is there a fix for CVE-2026-12774?
No fixed version is recorded yet. Check the vendor's advisory in the references below. If you run it, Junglewise drafts a mitigation that fits your setup and applies it once you approve, with senior security engineers behind it.
How is CVE-2026-12774 attacked?
It is attacked over the network, in a software library.
Am I affected by CVE-2026-12774?
Check whether you run Berriai LiteLLM at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

Technical details

A Server-Side Request Forgery (SSRF) vulnerability exists in LiteLLM up to version 1.82.2 within the `_execute_with_mcp_client` function of `litellm/proxy/_experimental/mcp_server/rest_endpoints.py`. The vulnerability is triggered via the `/v1/mcp/test/connection` management endpoint. When a user provides `client_id`, `client_secret`, and a `token_url` in the request payload, the application automatically initiates an OAuth2 client credentials flow. Because the `token_url` is not validated or restricted to a whitelist, an authenticated attacker can force the proxy to send HTTP POST requests to arbitrary internal or external IP addresses. This can be leveraged for internal network reconnaissance or to leak the provided `client_secret` to a malicious listener.

Affected products

  • BerriAI litellm <= 1.82.2

Timeline

  • 2026-03-21: disclosed: Initial public disclosure via GitHub Gist
  • 2026-06-21: advisory: NVD and VulDB publication

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.