CVE-2011-2894: Spring Framework Spring Framework And Spring Security Vulnerability
MODERATECVE-2011-2894 is a MODERATE spring framework and spring security vulnerability (CWE-502: Deserialization of Untrusted Data) affecting Spring Framework libraries in the Maven ecosystem. The issue involves spring framework and spring security vulnerable to deserialization of untrusted data. Remediation is available by upgrading affected packages to version 3.0.6, 2.0.7.
CVE-2011-2894 at a Glance
How to Fix CVE-2011-2894
To remediate this vulnerability, upgrade all affected Spring Framework 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.springframework</groupId>
<artifactId>spring-core</artifactId>
<version>3.0.6</version>
</dependency>
<dependency>
<groupId>org.springframework.security</groupId>
<artifactId>spring-security-core</artifactId>
<version>3.0.6</version>
</dependency>
<dependency>
<groupId>org.springframework.security</groupId>
<artifactId>spring-security-core</artifactId>
<version>2.0.7</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.springframework
How to Check if You Are Affected
To determine whether your Java application is affected by CVE-2011-2894, inspect your build dependencies using the Maven Dependency Plugin:
mvn dependency:tree -Dincludes=org.springframework
Analyze the terminal output to locate any version of Spring Framework in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.0.6), your application is affected.
Note: The mvn dependency:tree -Dincludes=org.springframework 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-502: Deserialization of Untrusted Data, where the product deserializes untrusted data without sufficiently ensuring that the resulting data will be valid. In Spring Framework, 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-2011-2894 Affected Spring Framework Versions
3 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
org.springframework:spring-core
|
Maven |
≥ 3.0.0
< 3.0.6
|
3.0.6
|
|
org.springframework.security:spring-security-core
|
Maven |
≥ 3.0.0
< 3.0.6
|
3.0.6
|
|
org.springframework.security:spring-security-core
|
Maven |
≥ 2.0.0
< 2.0.7
|
2.0.7
|
References
Frequently Asked Questions
What is CVE-2011-2894?
Which Spring Framework versions are affected?
What version fixes CVE-2011-2894?
Is spring-core affected?
Is spring-security-core affected?
What CWE is associated with CVE-2011-2894?
How can I check Maven dependencies for CVE-2011-2894?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-f866-m9mv-2xr3",
"modified" : "2024-03-14T21:21:36Z",
"published" : "2022-05-14T02:54:56Z",
"aliases" : [ "CVE-2011-2894" ],
"summary" : "Spring Framework and Spring Security vulnerable to Deserialization of Untrusted Data",
"details" : "Spring Framework 3.0.0 through 3.0.5, Spring Security 3.0.0 through 3.0.5 and 2.0.0 through 2.0.6, and possibly other versions deserialize objects from untrusted sources, which allows remote attackers to bypass intended security restrictions and execute untrusted code by (1) serializing a java.lang.Proxy instance and using InvocationHandler, or (2) accessing internal AOP interfaces, as demonstrated using deserialization of a DefaultListableBeanFactory instance to execute arbitrary commands via the java.lang.Runtime class.",
"severity" : [ ],
"affected" : [ {
"package" : {
"ecosystem" : "Maven",
"name" : "org.springframework:spring-core"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "3.0.0"
}, {
"fixed" : "3.0.6"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Maven",
"name" : "org.springframework.security:spring-security-core"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "3.0.0"
}, {
"fixed" : "3.0.6"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Maven",
"name" : "org.springframework.security:spring-security-core"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "2.0.0"
}, {
"fixed" : "2.0.7"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2011-2894"
}, {
"type" : "WEB",
"url" : "https://github.com/spring-projects/spring-framework/commit/070a723ef2c886770a063eb9a67f84f74e06edfb"
}, {
"type" : "WEB",
"url" : "https://exchange.xforce.ibmcloud.com/vulnerabilities/69687"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/spring-projects/spring-framework"
}, {
"type" : "WEB",
"url" : "https://web.archive.org/web/20120307233721/http://www.springsource.com/security/cve-2011-2894"
}, {
"type" : "WEB",
"url" : "http://osvdb.org/75263"
}, {
"type" : "WEB",
"url" : "http://securityreason.com/securityalert/8405"
}, {
"type" : "WEB",
"url" : "http://www.redhat.com/support/errata/RHSA-2011-1334.html"
}, {
"type" : "WEB",
"url" : "http://www.securityfocus.com/archive/1/519593/100/0/threaded"
}, {
"type" : "WEB",
"url" : "http://www.securityfocus.com/bid/49536"
}, {
"type" : "WEB",
"url" : "http://www.springsource.com/security/cve-2011-2894"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-502" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2022-07-13T17:57:50Z",
"nvd_published_at" : "2011-10-04T10:55:00Z"
}
}