This vulnerability occurs when an application processes XML input without properly restricting external entity references. Attackers can exploit this to read local files, trigger internal network requests, or cause denial of service.
XML parsers often support Document Type Definitions (DTDs), which can define custom entities. When these entities point to external URIs (like file://, http://), the parser may fetch and include that external content. An attacker can inject a malicious DTD that references sensitive system files (e.g., /etc/passwd, C:\Windows\win.ini) or internal endpoints, leading to data exposure or server-side request forgery (SSRF). The retrieved data is often reflected in the application's output, such as error messages or API responses. Preventing XXE requires disabling DTD processing entirely or securely configuring the XML parser to reject external entities. Since manual code reviews and traditional SAST tools can miss parser configurations, managing this at scale is difficult; an ASPM like Plexicus can help you track and remediate these flaws across your entire stack by correlating findings with actual runtime behavior and suggesting prioritized fixes.
Impact: Read Application DataRead Files or Directories
If the attacker is able to include a crafted DTD and a default entity resolver is enabled, the attacker may be able to access arbitrary files on the system.
Impact: Bypass Protection Mechanism
The DTD may include arbitrary HTTP requests that the server may execute. This could lead to other attacks leveraging the server's trust relationship with other entities.
Impact: DoS: Resource Consumption (CPU)DoS: Resource Consumption (Memory)
The product could consume excessive CPU cycles or memory using a URI that points to a large file, or a device that always returns data such as /dev/random. Alternately, the URI could reference a file that contains many nested or recursive entity references to further slow down parsing.