Lucene search

K
githubGitHub Advisory DatabaseGHSA-6W63-H3FJ-Q4VW
HistoryJun 06, 2023 - 5:33 p.m.

fast-xml-parser vulnerable to Regex Injection via Doctype Entities

2023-06-0617:33:13
CWE-1333
GitHub Advisory Database
github.com
146
fast-xml-parser
vulnerability
fix
regex injection
doctype entities
patches
workarounds
software

7.5 High

CVSS3

Attack Vector

NETWORK

Attack Complexity

LOW

Privileges Required

NONE

User Interaction

NONE

Scope

UNCHANGED

Confidentiality Impact

NONE

Integrity Impact

NONE

Availability Impact

HIGH

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

7.4 High

AI Score

Confidence

High

0.001 Low

EPSS

Percentile

46.9%

Impact

“fast-xml-parser” allows special characters in entity names, which are not escaped or sanitized. Since the entity name is used for creating a regex for searching and replacing entities in the XML body, an attacker can abuse it for DoS attacks. By crafting an entity name that results in an intentionally bad performing regex and utilizing it in the entity replacement step of the parser, this can cause the parser to stall for an indefinite amount of time.

Patches

The problem has been resolved in v4.2.4

Workarounds

Avoid using DOCTYPE parsing by processEntities: false option.

Affected configurations

Vulners
Node
fast-xml-parser_projectfast-xml-parserRange<4.2.4node.js
CPENameOperatorVersion
fast-xml-parserlt4.2.4

7.5 High

CVSS3

Attack Vector

NETWORK

Attack Complexity

LOW

Privileges Required

NONE

User Interaction

NONE

Scope

UNCHANGED

Confidentiality Impact

NONE

Integrity Impact

NONE

Availability Impact

HIGH

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

7.4 High

AI Score

Confidence

High

0.001 Low

EPSS

Percentile

46.9%