CVE-2016-6795: Path Traversal in Apache Struts
9.8
CVSS Score
3.0
Basic Information
CVE ID
GHSA ID
EPSS Score
0.93592%
CWE
Published
5/14/2022
Updated
1/4/2024
KEV Status
No
Technology
Java
Technical Details
CVSS Vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
org.apache.struts:struts2-convention-plugin | maven | >= 2.3.0, < 2.3.31 | 2.3.31 |
org.apache.struts:struts2-convention-plugin | maven | >= 2.5.0, < 2.5.5 | 2.5.5 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from insufficient path validation in the ConventionUnknownHandler's resource lookup logic. The original code in findResult()
checked only if a resource exists (via servletContext.getResource()
and ClassLoaderUtil.getResource()
), but did not verify if the resolved resource's actual path matched the requested path. This allowed crafted URLs with '../' sequences to access arbitrary resources. The patch introduced an additional check (resource.getPath().endsWith(path)
), which directly addresses this flaw. The function's role in mapping URLs to resources and the specific nature of the vulnerability (path traversal via Convention plugin) make this the clear entry point for exploitation.