mo has a XSS via inline SVG script tags in Markdown rendering
Key facts
- Attack vector
- —
- Privileges required
- —
- User interaction
- —
- Attack complexity
- —
- Impact type
- Cross-site scripting
- Confidentiality · integrity · availability
- —
- Fix status
- Fixed
No CVSS vector from any source. Fix status from GitHub. Impact type from CWE-79.
Summary
### Summary When rendering Markdown files containing inline SVG elements with `<script>` tags, the embedded JavaScript is executed in the browser. This is due to `rehype-raw` passing raw HTML (including SVG) through to the DOM without sanitization. ### PoC ```html <svg><script>alert(1)</script></svg> ``` Embedding the above in a Markdown file opened with mo causes the script to execute. ### Impact Arbitrary JavaScript execution in the context of the mo application when a user opens a malicious Markdown file. This could lead to data exfiltration of other opened Markdown file contents. ### Remediation Fixed by adding `rehype-sanitize` to the Markdown rendering pipeline, which strips dangerous elements such as `<script>` while preserving safe HTML.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| — | github.com/k1LoW/mo (Go) | before 0.18.5 | 0.18.5 | Patch available | GHSA-vccx-p757-pv6h |
- github.com/k1LoW/mo (Go) Vendor— Affected before 0.18.5 Fixed in 0.18.5 Patch available GHSA-vccx-p757-pv6h
Remediation
- Fix · GHSA-vccx-p757-pv6h github.com/k1LoW/mo (Go) Fixed in 0.18.5 Advisory →
Timeline
- 2026-10-03 Threatist record created from GHSA-vccx-p757-pv6h
References
Sources
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences