@xmldom/xmldom is vulnerable to Regular Expression Denial of Service (ReDoS)
87
High Risk
The processing-instruction grammar regular expression in the parser backtracks quadratically when it encounters an unterminated processing instruction. A small document with a long run of whitespace after an unterminated processing instruction forces the regex engine into O(n^2) work, stalling the single-threaded event loop. The input is reachable through DOMParser.parseFromString with default options, so untrusted XML from network sources can trigger the slowdown. The fix inserts a fixed-width negative lookahead after the whitespace separator so the pattern can no longer backtrack.
You are affected if you are using a version that falls within the vulnerable range and you parse untrusted XML using DOMParser.parseFromString.
@xmldom/xmldom is vulnerable to Regular Expression Denial of Service (ReDoS) in versions 0.9.0 - 0.9.10.
Upgrade the @xmldom/xmldom library to the patch version.
Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.
Free. No credit card required.

I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant