Security mailing lists by PureSourceCode

CVE-2025-23207

HIGH 7.2CVSS 3.1

KaTeX \htmlData does not validate attribute names

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.

Published
17 Jan 2025
Last modified
17 Jun 2026
Assigned by
security-advisories@github.com
NVD status
Analyzed
Weakness
CWE-116CWE-79
Also known as
GHSA-cg87-wmx4-v546
Sources
NVDJSONOSV GHSA-cg87-wmx4-v546JSON

Scores

SourceScored byVersionScoreVector / decision
NVD nvd@nist.gov (Primary) CVSS 3.1 HIGH 7.2 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N
NVD security-advisories@github.com (Secondary) CVSS 3.1 MEDIUM 6.3 CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L
OSV GitHub CVSS 3.1 MEDIUM 6.3 CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L

Affected

SourceVendor / ecosystemProduct / packageAffected versionsFixed in
NVD katex katex
cpe:2.3:a:katex:katex:*:*:*:*:*:*:*:*
>= 0.12.0, < 0.16.21 0.16.21
OSV npm katex >= 0.12.0, < 0.16.21 0.16.21

References

History

  • 25 Nov 2026 20:57 UTC · NVD: first stored (published 17 Jan 2025)
  • 25 Nov 2026 20:11 UTC · OSV: first stored (published 17 Jan 2025)
An unhandled error has occurred. Reload ×

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.