What’s Vulnerable › Vulnerabilities
CVE-2025-54880: Mermaid does not properly sanitize architecture diagram iconText leading to XSS
- Severity: medium (CVSS 6.1 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.4% probability of exploitation in the next 30 days
- Public exploit or detection template: yes
- Published: 2025-08-19 · updated 2026-06-17
- Weakness: CWE-79
Description
Mermaid is a JavaScript based diagramming and charting tool that uses Markdown-inspired text definitions and a renderer to create and modify complex diagrams. In the default configuration of mermaid 11.9.0 and earlier, user supplied input for architecture diagram icons is passed to the d3 html() method, creating a sink for cross site scripting. This vulnerability is fixed in 11.10.0.
Affected products
- mermaid-js mermaid: from 11.1.0 before 11.10.0 — fixed in 11.10.0
How to fix
Upgrade to a fixed version: mermaid-js mermaid 11.10.0. Check the vendor advisory for mitigations.
References
- https://github.com/mermaid-js/mermaid/commit/2aa83302795183ea5c65caec3da1edd6cb4791fc
- https://github.com/mermaid-js/mermaid/commit/734bde38777c9190a5a72e96421c83424442d4e4
- https://github.com/mermaid-js/mermaid/security/advisories/GHSA-8gwm-58g9-j8pw
- https://github.com/mermaid-js/mermaid/security/advisories/GHSA-8gwm-58g9-j8pw
Get alerted when CVE-2025-54880 or the next vulnerability affects your stack