CVE-2026-50159 Details
Description
Mermaid is a JavaScript tool that uses Markdown-inspired text to create and modify diagrams and charts. Prior to 10.9.8 and 11.16.1, Mermaid is vulnerable to CSS injection via sibling combinator selectors generated from diagram-supplied class or id names. An attacker who can supply diagram text can inject arbitrary CSS into the rendered page, potentially altering the appearance or behavior of unrelated page elements. This issue is fixed in versions 10.9.8 and 11.16.1.
A CSS injection vulnerability has been identified in Mermaid, a JavaScript tool for creating diagrams and charts from Markdown-inspired text. This issue affects versions prior to 10.9.8 and 11.16.1. The vulnerability arises from the improper handling of sibling combinator selectors, which can be exploited by injecting arbitrary CSS into the rendered page. An attacker who can supply diagram text may alter the appearance or behavior of unrelated page elements. While most users are not affected, those manually inserting SVG elements into the DOM could be vulnerable.
Users can update to Mermaid versions 10.9.8 or 11.16.1, both of which include the necessary fix. Instructions for downloading these versions are available on the Mermaid GitHub releases page.
Metrics
CVSS 4.0 Severity and Vector Strings:
CVSS 3.x Severity and Vector Strings:
No CVSS 3.x data is available for this CVE.
No data available for CVSS Version 2.0 on this CVE.
CISA-ADP
Assessed Aug 7, 2026References 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.
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-94 | Improper Control of Generation of Code ('Code Injection') | [email protected] |
Affected Products
No affected product data is available for this CVE.
Change History
2 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Aug 7, 2026 | CVE Modified | CISA-ADP |
| Aug 6, 2026 | New CVE Received | [email protected] |