p PatchFirst

CVE-2025-23207

CVE-2025-23207 · \htmlData does not validate attribute names in KaTeX

This page contains facts from public vulnerability sources. Check the original advisory before updating.

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.

CVSS 6.3 · Medium · EPSS 0.4% · Fix available

Published
Updated

Stack: system · node

Affected products and versions

  • katex

    Versions
    • >= 0.12.0, < 0.16.21: Affected

    No fix published

  • node-katex Debian:12

    Versions
    • 0.16.10+~cs6.1.0-1
    • 0.16.10+~cs6.1.0-2
    • 0.16.10+~cs6.1.0-3
    • 0.16.10+~cs6.1.0-4
    • 0.16.10+~cs6.1.0-5
    • 0.16.10+~cs6.1.0-6
    • 0.16.10+~cs6.1.0-7
    • 0.16.10+~cs6.1.0-8
    • 0.16.10+~cs6.1.0-9
    • 0.16.4+~cs6.1.0-1
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • node-katex Debian:13

    Versions
    • 0.16.10+~cs6.1.0-2
    • 0.16.10+~cs6.1.0-3
    • 0.16.10+~cs6.1.0-4
    • 0.16.10+~cs6.1.0-5
    • 0.16.10+~cs6.1.0-6
    • 0.16.10+~cs6.1.0-7
    • 0.16.10+~cs6.1.0-8
    • 0.16.10+~cs6.1.0-9
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • node-katex Debian:14

    Versions
    • 0.16.10+~cs6.1.0-2
    • 0.16.10+~cs6.1.0-3
    • 0.16.10+~cs6.1.0-4
    • 0.16.10+~cs6.1.0-5
    • 0.16.10+~cs6.1.0-6
    Affected ranges
    • ECOSYSTEM: < 0.16.10+~cs6.1.0-7

    Update to 0.16.10+~cs6.1.0-7

  • katex npm

    Affected ranges
    • SEMVER: ≥ 0.12.0, < 0.16.21

    Update to 0.16.21

  • node-katex Ubuntu:Pro:22.04:LTS

    Versions
    • 0.10.2+dfsg-8
    • 0.10.2+dfsg-9
    • 0.10.2+dfsg-10
    • 0.13.11+~cs6.0.0-2
    Affected ranges
    • ECOSYSTEM: < 0.13.11+~cs6.0.0-2ubuntu0.1~esm1

    Update to 0.13.11+~cs6.0.0-2ubuntu0.1~esm1

  • node-katex Ubuntu:Pro:24.04:LTS

    Versions
    • 0.16.4+~cs6.1.0-1
    • 0.16.10+~cs6.1.0-2
    Affected ranges
    • ECOSYSTEM: < 0.16.10+~cs6.1.0-2ubuntu0.24.04.1~esm1

    Update to 0.16.10+~cs6.1.0-2ubuntu0.24.04.1~esm1

  • node-katex Ubuntu:25.10

    Versions
    • 0.16.10+~cs6.1.0-2
    Affected ranges
    • ECOSYSTEM: < 0.16.10+~cs6.1.0-2ubuntu1

    Update to 0.16.10+~cs6.1.0-2ubuntu1

  • node-katex Ubuntu:26.04:LTS

    Affected ranges
    • ECOSYSTEM: < 0.16.10+~cs6.1.0-2ubuntu1

    Update to 0.16.10+~cs6.1.0-2ubuntu1

Original sources

Check your server →