CVE-2008-5515: Path Traversal
Apache Tomcat 4.1.0 through 4.1.39, 5.5.0 through 5.5.27, 6.0.0 through 6.0.18, and possibly earlier versions normalizes the target pathname before filtering the query string when using the RequestDispatcher method, which allows remote attackers to bypass intended access restrictions and conduct directory traversal attacks via .. (dot dot) sequences and the WEB-INF directory in a Request.
Other sources
http://marc.info/?l=tomcat-dev&m=124449799021570&w=2
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
CVE-2008-5515: Apache Tomcat information disclosure vulnerability
Severity: Important
Vendor: The Apache Software Foundation
Versions Affected: Tomcat 4.1.0 to 4.1.39 Tomcat 5.5.0 to 5.5.27 Tomcat 6.0.0 to 6.0.18 The unsupported Tomcat 3.x, 4.0.x and 5.0.x versions may be also affected
Description: When using a RequestDispatcher obtained from the Request, the target path was normalised before the query string was removed. A request that included a specially crafted request parameter could be used to access content that would otherwise be protected by a security constraint or by locating it in under the WEB-INF directory.
Mitigation: 6.0.x users should upgrade to 6.0.20 or apply this patch: http://svn.apache.org/viewvc?view=rev&revision=734734 5.5.x users should upgrade to 5.5.28 when released or apply this patch: http://svn.apache.org/viewvc?view=rev&revision=782757 4.1.x users should upgrade to 4.1.40 when released or apply this patch: http://svn.apache.org/viewvc?view=rev&revision=782763
Example: For a page that contains: <% request.getRequestDispatcher( "bar.jsp?somepar=someval&par=" + request.getParameter( "blah" ) ).forward( request, response ); %>
an attacker can use: http://host/page.jsp?blah=/../WEB-INF/web.xml
Credit: This issue was discovered by Iida Minehiko, Fujitsu Limited
References: http://tomcat.apache.org/security.html -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iEYEARECAAYFAkotiBQACgkQb7IeiTPGAkMi6QCgnlzEt/7byUJo2YXGHMLj2ckH rF8AoK8dmpZcxd5pV9VvEaPqm4xhXJPO =bDV5 -----END PGP SIGNATURE-----
— Red Hat
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
maven/org.apache.tomcat:tomcatto a version that resolves this vulnerability.Fixed in 6.0.20 - Upgrade
Upgrade
maven/org.apache.tomcat:tomcatto a version that resolves this vulnerability.Fixed in 5.5.28 - Upgrade
Upgrade
maven/org.apache.tomcat:tomcatto a version that resolves this vulnerability.Fixed in 4.1.40 - Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 4.1.40 - Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 5.5.28 - Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 6.0.20
Event History
Frequently Asked Questions
What is the severity of CVE-2008-5515?
The severity of CVE-2008-5515 is considered high due to the potential for unauthorized access to restricted resources.
How do I fix CVE-2008-5515?
You can fix CVE-2008-5515 by upgrading to Apache Tomcat version 5.5.28, 6.0.20, or 4.1.40, which contain the necessary patches.
What versions of Apache Tomcat are affected by CVE-2008-5515?
Apache Tomcat versions 4.1.0 through 4.1.39, 5.5.0 through 5.5.27, and 6.0.0 through 6.0.18 are affected by CVE-2008-5515.
Can CVE-2008-5515 lead to data breaches?
Yes, CVE-2008-5515 can allow remote attackers to bypass access restrictions, potentially leading to data breaches.
What type of vulnerability is CVE-2008-5515?
CVE-2008-5515 is a path traversal vulnerability that exploits improper pathname normalization in Apache Tomcat.