CVE-2023-42794: Apache Tomcat Apache Tomcat Incomplete Cleanup Vulnerability Vulnerability
MODERATECVE-2023-42794 is a MODERATE (CVSS 5.9) apache tomcat incomplete cleanup vulnerability vulnerability (CWE-459: Incomplete Cleanup) affecting Apache Tomcat libraries in the Maven ecosystem. The issue involves apache tomcat incomplete cleanup vulnerability. Remediation is available by upgrading affected packages to version 9.0.81, 8.5.94.
CVE-2023-42794 at a Glance
Security Impact
CVSS: 5.9
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H).
How to Fix CVE-2023-42794
To remediate this vulnerability, upgrade all affected Apache Tomcat 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.apache.tomcat</groupId>
<artifactId>tomcat-coyote</artifactId>
<version>9.0.81</version>
</dependency>
<dependency>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-coyote</artifactId>
<version>8.5.94</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.apache.tomcat
How to Check if You Are Affected
To determine whether your Java application is affected by CVE-2023-42794, inspect your build dependencies using the Maven Dependency Plugin:
mvn dependency:tree -Dincludes=org.apache.tomcat
Analyze the terminal output to locate any version of Apache Tomcat in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 9.0.81), your application is affected.
Note: The mvn dependency:tree -Dincludes=org.apache.tomcat 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-459: Incomplete Cleanup, where the product does not properly "clean up" and remove temporary or supporting resources after they have been used. In Apache Tomcat, 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-42794 Affected Apache Tomcat Versions
2 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
org.apache.tomcat:tomcat-coyote
|
Maven |
≥ 9.0.70
< 9.0.81
|
9.0.81
|
|
org.apache.tomcat:tomcat-coyote
|
Maven |
≥ 8.5.85
< 8.5.94
|
8.5.94
|
References
Frequently Asked Questions
What is CVE-2023-42794?
Which Apache Tomcat versions are affected?
What version fixes CVE-2023-42794?
Is tomcat-coyote affected?
What is the CVSS score of CVE-2023-42794?
What CWE is associated with CVE-2023-42794?
How can I check Maven dependencies for CVE-2023-42794?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-jm7m-8jh6-29hp",
"modified" : "2025-02-13T19:16:22Z",
"published" : "2023-10-10T18:31:35Z",
"aliases" : [ "CVE-2023-42794" ],
"summary" : "Apache Tomcat Incomplete Cleanup vulnerability",
"details" : "Incomplete Cleanup vulnerability in Apache Tomcat.\n\nThe internal fork of Commons FileUpload packaged with Apache Tomcat 9.0.70 through 9.0.80 and 8.5.85 through 8.5.93 included an unreleased, in progress refactoring that exposed a potential denial of service on Windows if a web application opened a stream for an uploaded file but failed to close the stream. The file would never be deleted from disk creating the possibility of an eventual denial of service due to the disk being full.\n\nUsers are recommended to upgrade to version 9.0.81 onwards or 8.5.94 onwards, which fixes the issue.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Maven",
"name" : "org.apache.tomcat:tomcat-coyote"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "9.0.70"
}, {
"fixed" : "9.0.81"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Maven",
"name" : "org.apache.tomcat:tomcat-coyote"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "8.5.85"
}, {
"fixed" : "8.5.94"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2023-42794"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/apache/tomcat"
}, {
"type" : "WEB",
"url" : "https://lists.apache.org/thread/vvbr2ms7lockj1hlhz5q3wmxb2mwcw82"
}, {
"type" : "WEB",
"url" : "http://www.openwall.com/lists/oss-security/2023/10/10/8"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-459" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2023-10-10T22:30:15Z",
"nvd_published_at" : "2023-10-10T18:15:18Z"
}
}