CVE-2025-54881 Details
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 10.9.0-rc.1 to 11.9.0, user supplied input for sequence diagram labels is passed to innerHTML during calculation of element size, causing XSS.
A cross-site scripting (XSS) vulnerability has been identified in the Mermaid JavaScript library, specifically in versions 10.9.0-rc.1 through 11.9.0. The issue arises in the default configuration when user-supplied input for sequence diagram labels is processed. The input is passed to 'innerHTML' without proper sanitization, allowing for the injection of malicious HTML that can be executed in the user's browser.
Users can update to Mermaid version 11.10.0 or later, where this vulnerability has been addressed.
Metrics
CVSS 4.0 Severity and Vector Strings:
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
Volerion
Assessed Aug 19, 2025CISA-ADP
Assessed Aug 19, 2025References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://github.com/mermaid-js/mermaid/commit/5c69e5fdb004a6d0a2abe97e23d26e223a059832 | [email protected] | Source CodeVendor |
| https://github.com/mermaid-js/mermaid/commit/685516a85ec1df64cefd4fd15f26533be87d458e | [email protected] | Source CodeVendor |
| https://github.com/mermaid-js/mermaid/security/advisories/GHSA-7rqq-prvp-x9jh | [email protected] | AdvisoryExploitRemedyVendor |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-79 | Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| mermaid | >= 10.9.0-rc.1, <= 11.9.0 (semver) |
CPE
Remediation
| |
Change History
3 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jun 17, 2026 | CVE Modified | [email protected] |
| Jun 17, 2026 | CVE Modified | CISA-ADP |
| Aug 19, 2025 | New CVE Received | [email protected] |
Volerion