CVE-2025-58747

Medium

Description

Dify is an LLM application development platform. In Dify versions through 1.9.1, the MCP OAuth component is vulnerable to cross-site scripting when a victim connects to an attacker-controlled remote MCP server. The vulnerability exists in the OAuth flow implementation where the authorization_url provided by a remote MCP server is directly passed to window.open without validation or sanitization. An attacker can craft a malicious MCP server that returns a JavaScript URI (such as javascript:alert(1)) in the authorization_url field, which is then executed when the victim attempts to connect to the MCP server. This allows the attacker to execute arbitrary JavaScript in the context of the Dify application.

SeverityMedium
CVSS6.1
Exploit probability—
ProductLanggenius Dify
PublishedOct 17, 2025
First seenOct 17, 2025

How to fix

Update
  • langgenius dify1.9.2 or later

Affected products

ProductAffected versionsFixed in
langgenius difyv < 1.9.21.9.2

Check your version

Choose the product and enter the version you run to see whether it falls in the affected range.

In the Intelligence 360 plan

Attack Surface Management

See the assets tied to your domains, the technologies they run and known vulnerabilities in one list.