CVE-2026-26226: lukilabs beautiful-mermaid · XSS or 'Cross-site Scripting'
Affects lukilabs beautiful-mermaidSource CVE Database V5
Not known to be exploited · CVSS 5.3 Medium : upgrade to 0.1.3 when convenient.
Data as of 26 Oct 2026, 06:26 UTC
- EPSS
- 0.5% chance of exploitation in 30 days – higher than 47% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
- Patch
- Available – fixed in 0.1.3
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:NExploitation evidence
Disclosed: evidence found.
CVE published 13 Feb 2026
Detectable: no evidence on record.
No public nuclei template indexed
Weaponised: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 2026-10-26.
What to do
Upgrade lukilabs beautiful-mermaid to 0.1.3.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| lukilabsbeautiful-mermaid | Affected
| Fixed in
|
GitHubbeautiful-mermaidpkg:github/beautiful-mermaidOther threats | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
Users should avoid rendering untrusted Mermaid diagrams with affected versions of beautiful-mermaid. Applying input sanitization or escaping on Mermaid style and classDef directives before rendering may reduce risk but is not a guaranteed fix.
Description
beautiful-mermaid versions prior to 0.1.3 contain an SVG attribute injection issue that can lead to cross-site scripting (XSS) when rendering attacker-controlled Mermaid diagrams. User-controlled values from Mermaid style and classDef directives are interpolated into SVG attribute values without proper escaping, allowing crafted input to break out of an attribute context and inject arbitrary SVG elements/attributes into the rendered output. When the generated SVG is embedded in a web page, this can result in script execution in the context of the embedding origin.
References
- github.com/lukilabs/beautiful-mermaid/releases/tag/v0.1.3 (opens in a new tab)
- github.com/lukilabs/beautiful-mermaid/pull/8 (opens in a new tab)
- neo.projectdiscovery.io/share/cec71dc7-a8eb-417e-b8b4-666644796c1e (opens in a new tab)
- vulncheck.com/advisories/beautiful-mermaid-svg-attribute-injection (opens in a new tab)