All vulnerabilities

Servers and applications

CVE-2026-31945

LibreChat Server-Side Request Forgery using DNS resolution

Severity
High 7.7
Published
27 Mar 2026
Last changed
26 Oct 2026
Added to UpHeron
1 Nov 2026
Exploit chance
0.3% in the next 30 daysHigher than 18% of CVEs. EPSS by FIRST, 19 Nov 2026
Weakness
Server-side request forgery (CWE-918)
Attack
Over the network · Needs a user account · No user action needed
Attacker can
Read data
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N
Also known as
GHSA-f92m-jpv7-55p2
Sources
NVD, Project advisories (GitHub)

Description

LibreChat version 0.8.2 remains vulnerable to a server-side request forgery (SSRF) attack when using agent actions or MCP. Although a previous SSRF vulnerability (https://github.com/danny-avila/LibreChat/security/advisories/GHSA-rgjq-4q58-m3q8) was reported and patched, the fix only introduced hostname validation. It does not verify whether DNS resolution results in a private IP address. As a result, an attacker can still bypass the protection and gain access to internal resources, such as an internal RAG API or cloud instance metadata endpoints.

After the SSRF vulnerability in agent actions and MCP was reported, a patch was introduced in version 0.8.2-rc2. (commit 3b41e392) However, isDomainAllowedCore and isSSRFTarget method assumes that the attackers only use localhost-like hostname or a direct private IP address. In practice, it remains possible to trigger SSRF by using a domain that resolves to a private IP address.

From LibreChat-AI/LibreChat's security advisory. Shortened; the full text is there.

Workarounds

A mitigation can be implemented by adding a method that verifies whether the validated hostname resolves to a private IP address after DNS resolution.

  • packages/api/src/auth/domain.ts

However, this is only a preliminary patch and does not protect against TOCTOU (Time-of-Check to Time-of-Use) attacks. To properly mitigate this risk, validation must also be enforced at the point where the outbound request is made. In particular, the axios call within packages/data-provider/src/actions.ts should perform its own verification of the resolved IP address immediately before sending the request.

Workarounds as given by LibreChat-AI/LibreChat's security advisory.

Affected software

SoftwareAffected versions
LibreChatServers and applications · cpe:a:librechat:librechat
  • Version 0.8.2-rc2
  • Version 0.8.2-rc3
  • Version 0.8.2
LibreChatServers and applications · github:librechat-ai/librechat
  • Version 0.8.2-rc2
  • Version 0.8.2-rc3
  • Version 0.8.2

About LibreChat

Enhanced ChatGPT Clone: Features Agents, MCP, Skills, DeepSeek, Anthropic, AWS, OpenAI, Responses API, Azure, Groq, o1, GPT-5, Mistral, OpenRouter, Vertex AI, Gemini, Artifacts, AI model switching, message search, Code Interpreter, langchain, DALL-E-3, OpenAPI Actions, Functions, Secure Multi-User Auth, Presets, open-source for self-hosting. Active

From its GitHub repository.
Docker Hub pulls
669,094Docker Hub, 15 Nov 2026
GitHub stars
47,138GitHub, 15 Nov 2026
Forks
9,706GitHub, 15 Nov 2026
License
MITGitHub
First published on GitHub
12 Feb 2023GitHub

References

  • NVD https://nvd.nist.gov/vuln/detail/CVE-2026-31945
  • CVE.org https://www.cve.org/CVERecord?id=CVE-2026-31945
  • GitHub Advisory Database https://github.com/advisories/GHSA-f92m-jpv7-55p2
  • github.com https://github.com/LibreChat-AI/LibreChat/security/advisories/GHSA-f92m-jpv7-55p2