Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. fast-xml-parser
  4. ›
  5. CVE-2026-33349

CVE-2026-33349: Entity Expansion Limits Bypassed When Set to Zero Due to JavaScript Falsy Evaluation in fast-xml-parser

March 19, 2026

The DocTypeReader in fast-xml-parser uses JavaScript truthy checks to evaluate maxEntityCount and maxEntitySize configuration limits. When a developer explicitly sets either limit to 0 — intending to disallow all entities or restrict entity size to zero bytes — the falsy nature of 0 in JavaScript causes the guard conditions to short-circuit, completely bypassing the limits. An attacker who can supply XML input to such an application can trigger unbounded entity expansion, leading to memory exhaustion and denial of service.

References

  • github.com/NaturalIntelligence/fast-xml-parser
  • github.com/NaturalIntelligence/fast-xml-parser/security/advisories/GHSA-jp2q-39xq-3w4g
  • github.com/advisories/GHSA-jp2q-39xq-3w4g
  • nvd.nist.gov/vuln/detail/CVE-2026-33349

Code Behaviors & Features

Detect and mitigate CVE-2026-33349 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 4.0.0-beta.3 before 5.5.7

Fixed versions

  • 5.5.7

Solution

Upgrade to version 5.5.7 or above.

Impact 5.9 MEDIUM

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

Learn more about CVSS

Weakness

  • CWE-1284: Improper Validation of Specified Quantity in Input

Source file

npm/fast-xml-parser/CVE-2026-33349.yml

Spotted a mistake? Edit the file on GitLab.

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

Page generated Tue, 24 Mar 2026 12:19:23 +0000.