{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2025-54881","id":"CVE-2025-54881","title":"Mermaid improperly sanitizes of sequence diagram labels leading to XSS","description":"Mermaid is a JavaScript based diagramming and charting tool that uses Markdown-inspired text definitions and a renderer to create and modify complex diagrams. In the default configuration of mermaid 10.9.0-rc.1 to 11.9.0, user supplied input for sequence diagram labels is passed to innerHTML during calculation of element size, causing XSS.","descriptionLong":"Mermaid is a JavaScript based diagramming and charting tool that uses Markdown-inspired text definitions and a renderer to create and modify complex diagrams. In the default configuration of mermaid 10.9.0-rc.1 to 11.9.0, user supplied input for sequence diagram labels is passed to innerHTML during calculation of element size, causing XSS.","published":"2025-08-19T17:04:29.453Z","updated":"2026-10-28T02:30:43.025831849Z","reserved":"2025-07-31T17:23:33.475Z","status":"Deferred","rejected":false,"assigner":"GitHub_M","metric":{"version":"4.0","score":5.3,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N","rating":"medium","source":"GitHub_M"},"metrics":[{"version":"4.0","score":5.3,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N","rating":"medium","source":"GitHub_M"},{"version":"4.0","score":5.3,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","rating":"medium","source":"github.com"},{"version":"4.0","score":null,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N","rating":"unrated","source":"OSV"},{"version":"4.0","score":null,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N","rating":"medium","source":"GitHub"}],"rating":"medium","products":["mermaid-js mermaid"],"affectedProducts":[{"vendor":"mermaid-js","product":"mermaid","defaultStatus":null,"versions":[{"version":">= 10.9.0-rc.1, <= 11.9.0","status":"affected"}],"platforms":[]}],"packages":[{"ecosystem":"npm","name":"mermaid","purl":"pkg:npm/mermaid","ranges":[">=11.0.0-alpha.1 <11.10.0",">=10.9.0-rc.1 <10.9.4"],"fixed":["11.10.0","10.9.4"],"advisory":"GHSA-7rqq-prvp-x9jh"}],"cwes":["CWE-79"],"aliases":["GHSA-7rqq-prvp-x9jh"],"references":[{"url":"https://github.com/mermaid-js/mermaid/security/advisories/GHSA-7rqq-prvp-x9jh","tags":["x_refsource_CONFIRM","advisory","web"]},{"url":"https://github.com/mermaid-js/mermaid/commit/5c69e5fdb004a6d0a2abe97e23d26e223a059832","tags":["x_refsource_MISC","fix","web"]},{"url":"https://github.com/mermaid-js/mermaid/commit/685516a85ec1df64cefd4fd15f26533be87d458e","tags":["x_refsource_MISC","fix","web"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/54xxx/CVE-2025-54881.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-54881","tags":["advisory"]},{"url":"https://github.com/mermaid-js/mermaid","tags":["package"]}],"patchReferenced":true,"fixAvailable":true,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"poc","automatable":"yes","technicalImpact":"partial"},"epss":0.00862,"epssPercentile":0.59323,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2025-54881","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-54881","ok":true,"note":"Deferred"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2025-54881","ok":true,"note":"1 package"},{"name":"GitHub Advisory","url":"https://github.com/advisories/GHSA-7rqq-prvp-x9jh","ok":true,"note":"GHSA-7rqq-prvp-x9jh"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2025-54881","ok":true,"note":"scored 2026-11-19"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}