CVE-2026-130866
Pastefy 7.2.1 before 7.2.7 Stored XSS via Mermaid Init Directive
Medium · 5.3Fix available
- CVSS
- 5.3
- EPSS
- 0.34% (p30)
- Published
- 2026-11-17
- Age
- 19d old
- Modified
- 2026-11-18
- Product
- InteraApps Pastefy
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N
Description
Pastefy 7.2.1 before 7.2.7 contains a stored cross-site scripting vulnerability in MermaidViewer.vue that passes attacker-supplied %%{init}%% directives to mermaid.mermaidAPI.updateSiteConfig(). Unauthenticated attackers can create Mermaid or Markdown pastes setting securityLevel to loose with a permissive dompurifyConfig to steal viewers' API session keys and act on their accounts.
Fixed in
7.2.7
Affected packages
| Ecosystem | Package | Range | Fixed |
|---|---|---|---|
| vendor | Pastefy | >=7.2.1, <7.2.7 | 7.2.7 |
Sources
- NVD · first seen 19d ago · NVD terms of use
- OSV · first seen 19d ago · CC-BY 4.0
- CVE List · first seen 19d ago · CVE Terms of Use
References
- https://github.com/interaapps/pastefy/issues/142 issue-tracking
- https://github.com/interaapps/pastefy/commit/caf35d8f279e2e1386a066753f2d644a0ba79507 patch
- https://github.com/interaapps/pastefy/releases/tag/7.2.7 release-notes
- https://github.com/interaapps/pastefy/blob/7.2.6/frontend/src/components/previews/MermaidViewer.vue#L28-L80 technical-description
- https://www.vulncheck.com/advisories/pastefy-7.2.1-before-7.2.7-stored-xss-via-mermaid-init-directive third-party-advisory
- https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/130xxx/CVE-2026-130866.json advisory
- https://github.com/interaapps/pastefy package
- https://nvd.nist.gov/vuln/detail/CVE-2026-130866 advisory