Vulnerability · Published Jan 21, 2026 · Assigned by GitHub_M
CVE-2026-23630Docmost is vulnerable to stored Cross-Site Scripting (XSS) through Mermaid rendering
Medium 6.3
In plain English
A medium-severity cross-site scripting in docmost from docmost. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.3% (higher than 22% of all known vulnerabilities).
Official description
Docmost is open-source collaborative wiki and documentation software. In versions 0.3.0 through 0.23.2, Mermaid code block rendering is vulnerable to stored Cross-Site Scripting (XSS). The frontend can render attacker-controlled Mermaid diagrams using mermaid.render(), then inject the returned SVG/HTML into the DOM via dangerouslySetInnerHTML without sanitization. Mermaid per-diagram %%{init}%% directives allow overriding securityLevel and enabling htmlLabels, permitting arbitrary HTML/JS execution for any viewer. This issue has been fixed in version 0.24.0.
Affected products (as reported)
Weakness: CWE-79, CWE-116 · Vector: CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:N/VI:N/VA:N/SC:H/SI:H/SA:N
References
- https://github.com/docmost/docmost/security/advisories/GHSA-r4hj-mc62-jmwj x_refsource_CONFIRM
- https://github.com/docmost/docmost/commit/cb9f27da9a8b4940760e37e5238a1eb91e427daf x_refsource_MISC
- https://github.com/docmost/docmost/releases/tag/v0.24.0 x_refsource_MISC