8.7high
fast-xml-parser: Repeated DOCTYPE declarations reset entity expansion limits
- Severity
- 8.7high CVSS:4.0 by GitHub_M
- Exploit likelihood
- 0.37% (higher than 33% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- GitHub_M
- Also known as
- GHSA-8r6m-32jq-jx6q
Description
fast-xml-parser allows users to process XML from JS object without C/C++ based libraries or callbacks. From 5.9.3 until 5.10.1, src/xmlparser/OrderedObjParser.js processes multiple DOCTYPE declarations within a single XML document and passes each declaration's entities through addInputEntities(). addInputEntities() resets maxTotalExpansions and maxExpandedLength every time it is called, allowing additional DOCTYPE declarations to repeatedly reset the configured entity-expansion limits during one parse operation. A crafted XML document can then cause excessive CPU use, event-loop blocking, memory exhaustion, and process termination. This issue is fixed in version 5.10.1.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| NaturalIntelligence fast-xml-parser | >= 5.9.3, < 5.10.1 | CVE List |
| fast-xml-parser (npm) | from 5.9.3 before 5.10.1 | GitHub Advisory Database |
All scores
| GitHub_M | 8.7high CVSS:4.0 | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N |
| GitHub | high CVSS:4.0 | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N |
Classification
SSVC (CISA-ADP): exploitation none, automatable yes, technical impact partial.
What each source says
CVE List
fast-xml-parser allows users to process XML from JS object without C/C++ based libraries or callbacks. From 5.9.3 until 5.10.1, src/xmlparser/OrderedObjParser.js processes multiple DOCTYPE declarations within a single XML document and passes each declaration's entities through addInputEntities(). addInputEntities() resets maxTotalExpansions and maxExpandedLength every time it is called, allowing additional DOCTYPE declarations to repeatedly reset the configured entity-expansion limits during one parse operation. A crafted XML document can then cause excessive CPU use, event-loop blocking, memory exhaustion, and process termination. This issue is fixed in version 5.10.1.
GitHub Advisory Database
Impact
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.
Workarounds
- Manually check if multiple DOCTYPEs are not present in input contents
- Update to v5.10.1
- Keep
processEntityflag off
NVD (es)
fast-xml-parser permite a los usuarios procesar XML desde un objeto JS sin bibliotecas basadas en C/C++ ni retrollamadas. Desde la versión 5.9.3 hasta la 5.10.1, src/xmlparser/OrderedObjParser.js procesa múltiples declaraciones DOCTYPE dentro de un único documento XML y pasa las entidades de cada declaración a través de addInputEntities(). addInputEntities() restablece maxTotalExpansions y maxExpandedLength cada vez que se llama, permitiendo que declaraciones DOCTYPE adicionales restablezcan repetidamente los límites de expansión de entidades configurados durante una operación de análisis. Un documento XML manipulado puede entonces causar un uso excesivo de la CPU, bloqueo del bucle de eventos, agotamiento de la memoria y terminación del proceso. Este problema se ha solucionado en la versión 5.10.1.
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2026-73569 changed 2026-08-13 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-8r6m-32jq-jx6q changed 2026-09-10 | CC-BY-4.0 |
| NVD | CVE-2026-73569 changed 2026-10-24 | Public domain |