Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. katex
  4. ›
  5. CVE-2024-28243

CVE-2024-28243: KaTeX's maxExpand bypassed by `\edef`

March 25, 2024

KaTeX users who render untrusted mathematical expressions could encounter malicious input using \edef that causes a near-infinite loop, despite setting maxExpand to avoid such loops. This can be used as an availability attack, where e.g. a client rendering another user’s KaTeX input will be unable to use the site due to memory overflow, tying up the main thread, or stack overflow.

References

  • github.com/KaTeX/KaTeX
  • github.com/KaTeX/KaTeX/commit/e88b4c357f978b1bca8edfe3297f0aa309bcbe34
  • github.com/KaTeX/KaTeX/security/advisories/GHSA-64fm-8hw2-v72w
  • github.com/advisories/GHSA-64fm-8hw2-v72w
  • nvd.nist.gov/vuln/detail/CVE-2024-28243

Code Behaviors & Features

Detect and mitigate CVE-2024-28243 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions starting from 0.10.0-beta before 0.16.10

Fixed versions

  • 0.16.10

Solution

Upgrade to version 0.16.10 or above.

Impact 6.5 MEDIUM

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

Learn more about CVSS

Weakness

  • CWE-606: Unchecked Input for Loop Condition

Source file

npm/katex/CVE-2024-28243.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 14 May 2025 12:15:13 +0000.