{"id":"CVE-2026-23630","summary":"Docmost is vulnerable to stored Cross-Site Scripting (XSS) through Mermaid rendering","details":"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.","aliases":["GHSA-r4hj-mc62-jmwj"],"modified":"2026-08-12T03:51:38.562603348Z","published":"2026-01-21T22:51:27.158Z","database_specific":{"cwe_ids":["CWE-116","CWE-79"],"osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/23xxx/CVE-2026-23630.json","cna_assigner":"GitHub_M"},"references":[{"type":"WEB","url":"https://github.com/docmost/docmost/releases/tag/v0.24.0"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/23xxx/CVE-2026-23630.json"},{"type":"ADVISORY","url":"https://github.com/docmost/docmost/security/advisories/GHSA-r4hj-mc62-jmwj"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-23630"},{"type":"FIX","url":"https://github.com/docmost/docmost/commit/cb9f27da9a8b4940760e37e5238a1eb91e427daf"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://github.com/docmost/docmost","events":[{"introduced":"73ddec4ca7415073d765cc62d100030223936b6c"},{"fixed":"0fe1459864ecc22582e5bae319537b30b705bacf"},{"fixed":"cb9f27da9a8b4940760e37e5238a1eb91e427daf"}],"database_specific":{"extracted_events":[{"introduced":"0.3.0"},{"fixed":"0.24.0"}],"source":["CPE_RANGE","REFERENCES"],"cpe":"cpe:2.3:a:docmost:docmost:*:*:*:*:*:*:*:*"}}],"versions":["v0.23.2","v0.23.1","v0.23.0","v0.22.2","v0.22.1","v0.22.0","v0.21.0","v0.20.4","v0.20.3","v0.20.2","v0.20.1","v0.20.0","v0.10.2","v0.10.1","v0.10.0","v0.9.0","v0.8.4","v0.8.3","v0.8.2","v0.8.1","v0.8.0","v0.7.0","v0.6.2","v0.6.1","v0.6.0","v0.5.0","v0.4.1","v0.4.0","v0.3.1","v0.3.0"],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-23630.json"}}],"schema_version":"1.9.0","severity":[{"type":"CVSS_V4","score":"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"}]}