Mermaid does not properly sanitize architecture diagram iconText leading to XSS
- Severity:
- Medium
Description
In the default configuration of mermaid 11.9.0, user supplied input for architecture diagram icons is passed to the d3 html() method, creating a sink for cross site scripting.
Recommendation
Update the mermaid package to the latest compatible version. Followings are version details:
- Affected version(s): >= 11.1.0, < 11.10.0
- Patched version(s): 11.10.0
References
Related Issues
- Mermaid improperly sanitizes sequence diagram labels leading to XSS - CVE-2025-54881
- vue-i18n's escapeParameterHtml does not prevent DOM-based XSS through its tag attributes (GHSA-x8qp-wqqm-57ph) 3 - CVE-2025-53892
- vue-i18n's escapeParameterHtml does not prevent DOM-based XSS through its tag attributes (GHSA-x8qp-wqqm-57ph) 4 - CVE-2025-53892
- vue-i18n's escapeParameterHtml does not prevent DOM-based XSS through its tag attributes (GHSA-x8qp-wqqm-57ph) - CVE-2025-53892
- Tags:
- npm
- mermaid
Anything's wrong? Let us know Last updated on August 20, 2025