Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. mdast-util-to-hast
  4. ›
  5. CVE-2025-66400

CVE-2025-66400: mdast-util-to-hast has unsanitized class attribute

December 2, 2025

Multiple (unprefixed) classnames could be added in markdown source by using character references. This could make rendered user supplied markdown code elements appear like the rest of the page. The following markdown:

```js xss
```

References

  • github.com/advisories/GHSA-4fh9-h7wg-q85m
  • github.com/syntax-tree/mdast-util-to-hast
  • github.com/syntax-tree/mdast-util-to-hast/commit/6fc783ae6abdeb798fd5a68e7f3f21411dde7403
  • github.com/syntax-tree/mdast-util-to-hast/commit/ab3a79570a1afbfa7efef5d4a0cd9b5caafbc5d7
  • github.com/syntax-tree/mdast-util-to-hast/security/advisories/GHSA-4fh9-h7wg-q85m
  • nvd.nist.gov/vuln/detail/CVE-2025-66400

Code Behaviors & Features

Detect and mitigate CVE-2025-66400 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 13.0.0 before 13.2.1

Fixed versions

  • 13.2.1

Solution

Upgrade to version 13.2.1 or above.

Impact 5.3 MEDIUM

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

Learn more about CVSS

Weakness

  • CWE-20: Improper Input Validation
  • CWE-915: Improperly Controlled Modification of Dynamically-Determined Object Attributes

Source file

npm/mdast-util-to-hast/CVE-2025-66400.yml

Spotted a mistake? Edit the file on GitLab.

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

Page generated Sun, 14 Dec 2025 00:18:46 +0000.