Skip to content
OpenAdvisories

Weakness (CWE)

CWE-643: Improper Neutralization of Data within XPath Expressions

Base Incomplete

The product uses external input to dynamically construct an XPath expression used to retrieve data from an XML database, but it does not neutralize or incorrectly neutralizes that input.

How to prevent it (2 mitigations)
  1. Implementation

    Use parameterized XPath queries (e.g. using XQuery). This will help ensure separation between data plane and control plane.

  2. Implementation

    Properly validate user input. Reject data where appropriate, filter where appropriate and escape where appropriate. Make sure input that will be used in XPath queries is safe in that context.

Source: MITRE CWE-643

2 results · Clear filters · Feed

  • Critical 9.1

    XML::Sig versions before 0.71 for Perl allow XPath injection in ID lookup

    XML::Sig versions before 0.71 for Perl allow XPath injection in ID lookup. verify() and _get_signed_xml() in lib/XML/Sig.pm build XPath expressions by concatenating the SignedInfo/Reference/@URI value read from the document being verified. The value is neithe…

  • Critical 9.9

    Plesk contains an XPath injection vulnerability in the APS Application Catalog search functionality, where user-supplie…