Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. fast-xml-parser
  4. ›
  5. GHSA-8r6m-32jq-jx6q

GHSA-8r6m-32jq-jx6q: fast-xml-parser: Repeated DOCTYPE declarations reset entity expansion limits

July 21, 2026

fast-xml-parser processes multiple “DOCTYPE” declarations within a single XML document. Each declaration passes its entities to @nodable/entities through addInputEntities().

addInputEntities() resets the entity expansion counters every time it is called. An attacker can therefore insert additional DOCTYPE declarations to repeatedly reset maxTotalExpansions and maxExpandedLength during one parse operation.

This allows a crafted XML document to exceed the configured entity-expansion limits and can cause excessive CPU use, event-loop blocking, memory exhaustion, and process termination.

References

  • github.com/NaturalIntelligence/fast-xml-parser/commit/4e546e03987662de5495d050b5fba26bea65383f
  • github.com/NaturalIntelligence/fast-xml-parser/releases/tag/v5.10.1
  • github.com/NaturalIntelligence/fast-xml-parser/security/advisories/GHSA-8r6m-32jq-jx6q
  • github.com/advisories/GHSA-8r6m-32jq-jx6q

Code Behaviors & Features

Detect and mitigate GHSA-8r6m-32jq-jx6q 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 5.9.3 before 5.10.1

Fixed versions

  • 5.10.1

Solution

Upgrade to version 5.10.1 or above.

Impact 7.5 HIGH

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

Learn more about CVSS

Weakness

  • CWE-776: Improper Restriction of Recursive Entity References in DTDs ('XML Entity Expansion')

Source file

npm/fast-xml-parser/GHSA-8r6m-32jq-jx6q.yml

Spotted a mistake? Edit the file on GitLab.

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

Page generated Sat, 08 Aug 2026 00:17:39 +0000.