CVE-2017-12617 — Apache Tomcat Remote Code Execution Vulnerability

CVE-2017-12617

Apache Tomcat — HTTP PUT JSP Upload RCE on All Platforms via Partial PUT Bypass; Companion to CVE-2017-12615 (Windows); Patched October 2017

What Is Apache Tomcat?

Apache Tomcat is the leading open-source Java application server, deployed in millions of enterprise environments globally. CVE-2017-12617 is the platform-independent companion to CVE-2017-12615 (Windows-only) — while CVE-2017-12615 was patched in Tomcat 7.0.81, CVE-2017-12617 represents a related but distinct bypass that works across all operating systems and affects Tomcat 8.x and 9.x versions.

Overview

Actively Exploited. This vulnerability has been added to CISA's Known Exploited Vulnerabilities (KEV) Catalog on March 25, 2022. Federal agencies are required to apply mitigations per BOD 22-01.

CVE-2017-12617 is a remote code execution vulnerability in Apache Tomcat (all platforms) caused by improper handling of HTTP PUT requests. When the DefaultServlet is configured with write permissions, a specially crafted PUT request can upload a JSP file to the server — which is then accessible via HTTP and executes server-side Java code. Unlike CVE-2017-12615 (Windows-specific trailing slash bypass), CVE-2017-12617 uses a different technique applicable to all platforms. Fixed in Apache Tomcat 8.5.24, 8.0.47, and 9.0.1 (October 2017). CISA added CVE-2017-12617 to the KEV catalog in March 2022.

Affected Versions

Tomcat Version Status
Apache Tomcat 9.0.0.M1 to 9.0.0 Vulnerable
Apache Tomcat 8.5.0 to 8.5.22 Vulnerable
Apache Tomcat 8.0.0.RC1 to 8.0.46 Vulnerable
Apache Tomcat 7.0.x (with PUT enabled) Separately patched by CVE-2017-12615
All above with October 2017 patch applied Fixed

Technical Details

Root Cause: JSP Upload via Partial PUT Request Bypass

CVE-2017-12617 is an unrestricted upload vulnerability (CWE-434) in Apache Tomcat's DefaultServlet. When readonly=false is configured, the DefaultServlet handles HTTP PUT for file uploads. The vulnerability involves sending a specially crafted PUT request (using partial PUT or specific URL encoding techniques) that bypasses Tomcat's check against uploading files with JSP extensions. The uploaded JSP is stored in the webapps directory and compiled by Tomcat when subsequently requested via HTTP GET.

Comparison with CVE-2017-12615:

Property CVE-2017-12615 CVE-2017-12617
Platform Windows only All platforms
Tomcat versions 7.x 8.x, 9.x
Bypass technique Windows trailing slash Partial PUT / encoding
Patch 7.0.81 8.5.24, 8.0.47, 9.0.1

Organizations running Tomcat 8.x or 9.x on Linux, macOS, or Windows need to patch CVE-2017-12617 — CVE-2017-12615 only applies to 7.x on Windows.

Attack Characteristics

Attribute Detail
Attack Vector Network — HTTP PUT to Tomcat DefaultServlet
Platform All operating systems
Payload JSP web shell → arbitrary Java RCE
Prerequisite DefaultServlet readonly=false

Exploitation Context

  • Cross-platform reach: CVE-2017-12617's platform-independence makes it more broadly applicable than CVE-2017-12615; Linux-hosted Tomcat (the most common production deployment) is affected
  • Automated scanning at scale: Exploit tools targeting both CVE-2017-12615 and CVE-2017-12617 were widely available immediately after patch release; mass scanning campaigns targeted Tomcat on standard ports globally
  • DevOps deployment patterns: Some CI/CD pipelines and deployment automation systems enable HTTP PUT on Tomcat for deploying WAR files or static content; these configurations were inadvertently enabling CVE-2017-12617 exploitation
  • CISA KEV (2022): Added March 25, 2022 alongside CVE-2017-12615 — both Apache Tomcat JSP upload vulnerabilities represent ongoing exploitation risk

Remediation

CISA BOD 22-01 Deadline: April 15, 2022. Apply mitigations per vendor instructions, follow applicable BOD 22-01 guidance for cloud services, or discontinue use of the product if mitigations are unavailable.
  1. Upgrade Apache Tomcat — update to Tomcat 8.5.24+, 8.0.47+, or 9.0.1+ to patch CVE-2017-12617. If running Tomcat 7.x on Windows, also ensure CVE-2017-12615 is patched (7.0.81+).

  2. Disable HTTP PUT — unless explicitly required, configure the DefaultServlet with readonly=true (the default); this mitigates both CVE-2017-12615 and CVE-2017-12617.

  3. Restrict access to Tomcat HTTP port — limit which network sources can reach the Tomcat HTTP port; legitimate users typically access Tomcat via a reverse proxy rather than directly.

  4. Deploy a reverse proxy — place Tomcat behind Apache httpd or nginx configured to block HTTP PUT requests; this provides an additional layer of protection independent of Tomcat's own configuration.

  5. Audit Tomcat webapps directories — check all webapps directories for unexpected .jsp files; any JSP not part of the deployed application is a potential web shell.

Key Details

PropertyValue
CVE ID CVE-2017-12617
Vendor / Product Apache — Tomcat
NVD Published2017-10-04
NVD Last Modified2025-10-22
CVSS 3.1 Score8.1
CVSS 3.1 VectorCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
SeverityHIGH
CWE CWE-434 — Unrestricted Upload of File with Dangerous Type find similar ↗
CISA KEV Added2022-03-25
CISA KEV Deadline2022-04-15
Known Ransomware Use No

CVSS 3.1 Breakdown

Attack Vector
Network
Attack Complexity
High
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

Required Action

CISA BOD 22-01 Deadline: 2022-04-15. Apply updates per vendor instructions.

Timeline

DateEvent
2017-10-03Apache releases Tomcat 8.5.24, 8.0.47, 9.0.1 patching CVE-2017-12617
2017-10-04CVE-2017-12617 published by NVD
2022-03-25Added to CISA Known Exploited Vulnerabilities catalog
2022-04-15CISA BOD 22-01 remediation deadline

References

ResourceType
NVD — CVE-2017-12617 Vulnerability Database
CISA KEV Catalog Entry US Government
Apache Tomcat 9.x Security Fixes Vendor Advisory