LiteLLM reflected XSS in SSO debug callback endpoint

Severity: medium · CVSS 6.8 · Published 2026-10-27

LiteLLM is a proxy service for managing large language model APIs. Its SSO debug callback endpoint reflects identity provider fields directly into JavaScript code without proper escaping, allowing attackers to inject malicious code. An attacker with an IdP account can craft a specially-formatted user claim that breaks out of the script context and executes arbitrary JavaScript in an admin's browser, potentially leading to admin account takeover.

Technologies: Berriai LiteLLM, litellm (PyPI). Vendors: Berriai, PyPI.

Quick answers

Is This vulnerability exploited in the wild?
No. Junglewise Threat Intelligence has no report of This vulnerability being exploited in the wild.
How severe is This vulnerability?
Medium severity, with a CVSS score of 6.8, published 27 October 2026.
Which products and versions are affected?
Berriai LiteLLM 1.65.5 through 1.84.x; litellm (PyPI) >= 1.65.5, < 1.85.0, ECOSYSTEM:introduced=1.65.5,fixed=1.85.0.
Is there a fix for This vulnerability?
Yes. litellm (PyPI): upgrade to 1.85.0 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is This vulnerability attacked?
It is attacked over the network.
Am I affected?
Check whether you run Berriai LiteLLM or litellm (PyPI) 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.

How to fix

  • litellm (PyPI): upgrade to 1.85.0 or later
    pip install "litellm>=1.85.0"

Technical details

The /sso/debug/callback endpoint uses json.dumps to embed IdP-controlled fields into an inline script block, which escapes JSON syntax but not HTML metacharacters like &lt;/script&gt;. An attacker with an IdP account can include &lt;/script&gt; in user claims to close the script tag and inject arbitrary JavaScript. The endpoint requires no authentication, but the attack requires user interaction (admin clicking a crafted callback URL) and the attacker must have an IdP account. A fix is available in version 1.85.0.

Affected products

  • BerriAI LiteLLM 1.65.5 through 1.84.x

Timeline

  • 2026-09-30: disclosed
  • 2026-10-27: advisory

References

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