Skip to main content

What it flags

Request data in the expression text passed to select, select1, evaluate or parse of the xpath package, for example xpath.select("//user[name='" + req.query.name + "']", doc) over an @xmldom/xmldom document. A value such as ' or '1'='1 rewrites the predicate and reads other nodes (CWE-643). Pass the value as an XPath variable (xpath.parse('//user[name=$name]').select({ node: doc, variables: { name } })) or match it against an allowlist first.

Configuration

Set the rule to "off" in loadwise.config.json to drop its findings: