CVE-2025-23207

HIGH CVSS 3.1: 7.2 EPSS 0.41%
Updated Sep 08, 2025
Katex
Parameter Value
CVSS 7.2 (HIGH)
Affected Versions 0.12.0 — 0.16.21
Fixed In 0.16.21
Type CWE-79 (Cross-Site Scripting (XSS)), CWE-116 (Improper Encoding or Escaping of Output)
Vendor Katex
Public PoC No

KaTeX is a fast, easy-to-use JavaScript library for TeX math rendering on the web. KaTeX users who render untrusted mathematical expressions with `renderToString` could encounter malicious input using `\htmlData` that runs arbitrary JavaScript, or generate invalid HTML. Users are advised to upgrade to KaTeX v0.16.21 to remove this vulnerability.

Users unable to upgrade should avoid use of or turn off the `trust` option, or set it to forbid `\htmlData` commands, forbid inputs containing the substring `"\\htmlData"` and sanitize HTML output from KaTeX.

Attack Parameters

Attack Vector
Network
Can be exploited remotely
Attack Complexity
Low
Easy to exploit
Privileges Required
None
No privileges needed
User Interaction
None
No user interaction needed

Impact Assessment

Confidentiality
Low
Partial data leak
Integrity
Low
Partial data modification
Availability
None
No disruption

CVSS Vector v3.1

Vulnerable Products 1

Configuration From (including) Up to (excluding)
Katex Katex
cpe:2.3:a:katex:katex:*:*:*:*:*:*:*:*
0.12.0 0.16.21

Related Vulnerabilities