Vulnerabilities in pkg:maven/org.dom4j/dom4j
PACKAGECVE-2023-45960 is a MODERATE dom4j xml entity expansion vulnerability vulnerability (CWE-776: Improper Restriction of Recursive Entity References in DTDs ('XML Entity Expansion')) affecting Withdrawn Advisory libraries in the Maven ecosystem. The issue involves dom4j xml entity expansion vulnerability. Remediation is available in the latest vendor maintenance releases.
pkg:maven/org.dom4j/dom4j
Vulnerability advisories affecting package pkg:maven/org.dom4j/dom4j. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-fgq9-fc3q-vqmw | CVE-2023-45960 | MODERATE | Withdrawn Advisory: dom4j XML Entity Expansion vulnerability |
| GHSA-6pcc-3rfx-4gpm | CVE-2018-1000632 | HIGH | Dom4j contains a XML Injection vulnerability |
| GHSA-hwj3-m3p6-hj38 | CVE-2020-10683 | CRITICAL | dom4j allows External Entities by default which might enable XXE attacks |
CVE-2023-45960 at a Glance
How to Fix CVE-2023-45960
To remediate this vulnerability, upgrade all affected Withdrawn Advisory dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
<dependency>
<groupId>org.dom4j</groupId>
<artifactId>dom4j</artifactId>
<version>Latest secure release</version>
</dependency>
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
mvn dependency:tree -Dincludes=org.dom4j
How to Check if You Are Affected
To determine whether your Java application is affected by CVE-2023-45960, inspect your build dependencies using the Maven Dependency Plugin:
mvn dependency:tree -Dincludes=org.dom4j
Analyze the terminal output to locate any version of Withdrawn Advisory in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than the patched release), your application is affected.
Note: The mvn dependency:tree -Dincludes=org.dom4j command inspects the resolved dependency graph declared in your project's POM files; it does not perform automated security scanning or inspect runtime dynamic classpaths. Always verify runtime container classpaths and shaded JARs.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-776: Improper Restriction of Recursive Entity References in DTDs ('XML Entity Expansion'), where the product uses xml documents and allows their structure to be defined with a document type definition (dtd), but it does not properly control the number of recursive definitions of entities. In Withdrawn Advisory, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2023-45960 Affected Withdrawn Advisory Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
org.dom4j:dom4j
|
Maven |
≤ 2.1.4
|
|
References
Frequently Asked Questions
What is CVE-2023-45960?
Which Withdrawn Advisory versions are affected?
What version fixes CVE-2023-45960?
Is dom4j affected?
What CWE is associated with CVE-2023-45960?
How can I check Maven dependencies for CVE-2023-45960?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-fgq9-fc3q-vqmw",
"modified" : "2023-10-31T20:21:23Z",
"published" : "2023-10-25T18:32:23Z",
"withdrawn" : "2023-10-31T20:21:23Z",
"aliases" : [ "CVE-2023-45960" ],
"summary" : "Withdrawn Advisory: dom4j XML Entity Expansion vulnerability",
"details" : "## Withdrawn Advisory\nThis advisory has been withdrawn because [the underlying vulnerability could not be reproduced](https://github.com/joker-xiaoyan/XXE-SAXReader/issues/1#issuecomment-1783780581). This link is maintained to preserve external references.\n\n## Original Description\nAn issue in dom4.j org.dom4.io.SAXReader v.2.1.4 and before allows a remote attacker to obtain sensitive information via the setFeature function.",
"severity" : [ ],
"affected" : [ {
"package" : {
"ecosystem" : "Maven",
"name" : "org.dom4j:dom4j"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"last_affected" : "2.1.4"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2023-45960"
}, {
"type" : "WEB",
"url" : "https://github.com/dom4j/dom4j/issues/171#issuecomment-1781547256"
}, {
"type" : "WEB",
"url" : "https://github.com/joker-xiaoyan/XXE-SAXReader/issues/1"
}, {
"type" : "WEB",
"url" : "https://dom4j.github.io"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/dom4j/dom4j"
}, {
"type" : "WEB",
"url" : "https://github.com/joker-xiaoyan/XXE-SAXReader/blob/8c0d24f9800c36c8ad36457c1df1e4aaff24c7b9/POC.java"
}, {
"type" : "WEB",
"url" : "https://github.com/joker-xiaoyan/XXE-SAXReader/tree/main"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-776" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2023-10-27T19:50:41Z",
"nvd_published_at" : "2023-10-25T18:17:35Z"
}
}