CVE-2012-4387: Xwork core Denial of Service Vulnerability
MODERATECVE-2012-4387 is a MODERATE denial of service vulnerability (General Security Weakness) affecting Xwork core libraries in the Maven ecosystem. The issue involves denial of service in apache struts. Remediation is available by upgrading affected packages to version 2.3.4.1.
CVE-2012-4387 at a Glance
How to Fix CVE-2012-4387
To remediate this vulnerability, upgrade all affected Xwork core 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.struts.xwork</groupId>
<artifactId>xwork-core</artifactId>
<version>2.3.4.1</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.struts.xwork
How to Check if You Are Affected
To determine whether your Java application is affected by CVE-2012-4387, inspect your build dependencies using the Maven Dependency Plugin:
mvn dependency:tree -Dincludes=org.apache.struts.xwork
Analyze the terminal output to locate any version of Xwork core in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.3.4.1), your application is affected.
Note: The mvn dependency:tree -Dincludes=org.apache.struts.xwork 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 General Security Weakness. In Xwork core, 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-2012-4387 Affected Xwork core Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
org.apache.struts.xwork:xwork-core
|
Maven |
≥ 2.0.0
< 2.3.4.1
|
2.3.4.1
|
References
Frequently Asked Questions
What is CVE-2012-4387?
Which Xwork core versions are affected?
What version fixes CVE-2012-4387?
Is xwork-core affected?
What CWE is associated with CVE-2012-4387?
How can I check Maven dependencies for CVE-2012-4387?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-hrgc-54mv-58gv",
"modified" : "2023-12-27T18:19:35Z",
"published" : "2022-05-17T01:42:17Z",
"aliases" : [ "CVE-2012-4387" ],
"summary" : "Denial of service in Apache Struts",
"details" : "Apache Struts 2.0.0 through 2.3.4 allows remote attackers to cause a denial of service (CPU consumption) via a long parameter name, which is processed as an OGNL expression.",
"severity" : [ ],
"affected" : [ {
"package" : {
"ecosystem" : "Maven",
"name" : "org.apache.struts.xwork:xwork-core"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "2.0.0"
}, {
"fixed" : "2.3.4.1"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2012-4387"
}, {
"type" : "WEB",
"url" : "https://github.com/apache/struts/commit/80e03182d66d9e6ab18f9a9a9b3c42725a1c89e9"
}, {
"type" : "WEB",
"url" : "https://github.com/apache/struts/commit/87935af56a27235e9399308ee1fcfb74f8edcefa"
}, {
"type" : "WEB",
"url" : "https://exchange.xforce.ibmcloud.com/vulnerabilities/78183"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/apache/struts"
}, {
"type" : "WEB",
"url" : "https://issues.apache.org/jira/browse/WW-3860"
}, {
"type" : "WEB",
"url" : "http://struts.apache.org/2.x/docs/s2-011.html"
}, {
"type" : "WEB",
"url" : "http://www.openwall.com/lists/oss-security/2012/09/01/4"
}, {
"type" : "WEB",
"url" : "http://www.openwall.com/lists/oss-security/2012/09/01/5"
} ],
"database_specific" : {
"cwe_ids" : [ ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2022-11-03T19:12:17Z",
"nvd_published_at" : "2012-09-05T23:55:00Z"
}
}