Skip to main content
Mallory
HighExploited in the wildCISA KEVPublic exploitVulnerability

CVE-2017-12615: Apache Tomcat remote code execution via JSP upload

Published Sep 19, 2017 · Updated 1 month ago
Trending this weekNot trendingOutside this week’s top 100
Mention activity · 30 daysNo mention activity in the last 30 days.
CVSS8.1High · v3.1
EPSS99.7%100th percentile
CISA KEVYesAdded Mar 25, 2022
In the wildActivePer CISA KEV
Vendors
NetAppRed HatApache Software Foundation
IdentifiersCVE-2017-12615CWE-20

CVE-2017-12615 is an input-validation vulnerability in Apache Tomcat's handling of HTTP PUT uploads. Apache Tomcat 7.0.0 through 7.0.79 on Windows is affected when HTTP PUT is enabled through a writable servlet context, such as by setting the DefaultServlet readonly initialization parameter to false. An attacker can upload a JSP file using a specially crafted request and subsequently request it to execute its embedded code on the server. Red Hat also identifies affected packaged Tomcat deployments on RHEL under writable-context configurations. The default read-only configuration does not expose this condition.

Do you run this?See affected versions in your environment and whether adversaries are exploiting this vulnerability against assets like yours.
Check your exposure
Analyst brief

Impact, mitigation & remediation

What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.

Impact

What an attacker gets, and what they’ve been doing with it.

Successful exploitation permits remote code execution on the Tomcat server and can compromise confidentiality, integrity, and availability. Observed exploitation includes deployment of webshells and execution of commands that download and launch malware. The available information does not establish automatic privilege escalation beyond the compromised server execution context.

Mitigation

If you can’t patch tonight, do this now.

Retain or restore readonly=true for the DefaultServlet, WebDAV servlet, and affected application contexts. Block HTTP PUT and other resource-modifying HTTP methods for untrusted users. Default read-only Tomcat configurations are not affected by the writable-context condition.

Remediation

Patch, then assume compromise.

Apply the vendor security update for the affected Tomcat distribution. Apache Tomcat 7.0.81 contains a fix for CVE-2017-12615, but that fix is bypassed by the separate CVE-2017-12617 vulnerability; select an update that addresses both issues. Red Hat fixes include RHSA-2017:3080 for RHEL 6 tomcat6, RHSA-2017:3081 for RHEL 7 tomcat, and RHSA-2017:3113 for JBoss Enterprise Web Server 2. Back up affected installations, applications, and configuration before updating.

Public exploits

Exploits

11 exploits validated by Mallory's analysis. Hidden: 3 rejected by Mallory's analysis as not a working exploit; 1 not yet analyzed, such as Exploit-DB entries.

View more in app →
cve-2017-12615This repository contains a Python exploit script (tomcatexploit.py) targeting CVE-2017-12615, a vulnerability in Apache Tomcat 7.0.0-7.0.79 (potentially more) on Windows systems. The exploit abuses a misconfiguration that allows HTTP PUT requests to upload files with a .jsp extension, enabling remote code execution. The script takes command-line arguments for the target IP, port, local JSP file to upload, and the remote filename. It constructs a URL to the target Tomcat server and uploads the specified JSP file using an HTTP PUT request. Once uploaded, the attacker can access the JSP file via the constructed URL, executing arbitrary code on the server. The repository also includes a minimal README.md. The exploit is operational, requiring the target to have PUT enabled and to be running a vulnerable Tomcat version on Windows. No hardcoded endpoints are present; the target is specified at runtime.mefulton · Disclosed Sep 25, 2017 · python · networkOperationalPOC-CVE-2017-12615-or-CVE-2017-12717This repository contains a Python proof-of-concept exploit for CVE-2017-12615 and CVE-2017-12617, targeting Apache Tomcat servers (primarily on Windows) with the HTTP PUT method enabled. The main file, 'tomcate-cve-put.py', attempts to upload a JSP webshell to the target server by sending a PUT request. If successful, the attacker can access the uploaded JSP file via HTTP and execute arbitrary system commands through a web interface. The exploit requires the attacker to specify the target host and the desired JSP filename. The repository is structured simply, with a README, a .gitignore, and the exploit script. The exploit is operational, as it provides a working payload (JSP webshell) and automates the attack process.zi0Black · Disclosed Oct 6, 2017 · python · networkOperationalcve-2017-12615This repository contains a single Python script, 'tomcat-cve-2017-12615.py', which exploits CVE-2017-12615, a vulnerability in Apache Tomcat (versions 7.0.0 to 7.0.81 on Windows) that allows arbitrary file upload via the HTTP PUT method. The script first checks if the PUT method is allowed by sending an OPTIONS request to a test endpoint. If allowed, it uploads a JSP webshell to a randomly named file on the server. The uploaded webshell allows remote command execution by sending HTTP requests with specific parameters. The script is operational and provides a working exploit with a hardcoded JSP payload. The main attack vector is network-based, targeting Tomcat servers accessible over HTTP. The script is self-contained, requires the target URL as an argument, and demonstrates the exploit's effectiveness by reporting the webshell's location if successful.wsg00d · Disclosed Nov 1, 2017 · python · networkOperationalCVE-2017-12615This repository contains a Python exploit script (CVE-2017-12615.py) targeting Apache Tomcat 7.0.0 to 7.0.79 servers with the HTTP PUT method enabled. The exploit works by uploading a malicious JSP file (webshell) to the server using a PUT request. The webshell allows remote command execution via the 'cmd' HTTP parameter. The script verifies successful upload by issuing a test command ('whoami') and then provides an interactive shell for the attacker to execute further commands. The README provides basic usage instructions and highlights the requirement for the PUT method to be enabled. The main fingerprintable endpoint is the '/1337.jsp/' path, which is used for both uploading and interacting with the webshell. The exploit is operational and provides a working remote command execution capability if the target is vulnerable.1337g · Disclosed Dec 26, 2017 · python · networkOperationalAttackTomcatThis repository is a Tomcat vulnerability exploitation toolkit with a Java GUI (JavaFX) and supporting Python script for AJP exploitation. It targets multiple vulnerabilities in Apache Tomcat: 1. **CVE-2017-12615 (PUT file upload)**: The tool attempts to upload a file (potentially a webshell) to the target Tomcat server using the HTTP PUT method. It then verifies if the upload was successful by attempting to access the uploaded file. 2. **Weak password brute-force**: The tool brute-forces Tomcat Manager or similar endpoints using configurable username and password lists (provided in `username.txt` and `password.txt`). 3. **CVE-2020-1938 (AJP file read/include)**: The toolkit includes a Python script (`ajpVul.py`) that exploits the AJP protocol to read arbitrary files or attempt remote code execution via file inclusion. The Java GUI calls this script as a subprocess. The main entry point is `main.java`, which launches a JavaFX GUI. The GUI allows users to configure proxies, set brute-force dictionaries, and launch the various exploits. The code is modular, with separate controllers for each exploit type and for proxy/dictionary configuration. The toolkit supports both HTTP and SOCKS proxies for network requests. **Notable endpoints and files:** - `/manager/html`: Target for brute-force attacks. - `/1092wxa.txt`: Test file for PUT upload. - `WEB-INF/web.xml`: Default file for AJP file read. - `config/ajpVul.py`: Python script for AJP exploitation. - TCP port 8009: Default AJP port. **Purpose:** The repository is designed for security testing of Apache Tomcat servers, providing detection and exploitation capabilities for several well-known vulnerabilities. It is intended for use by security professionals for penetration testing and self-assessment of Tomcat deployments.tpt11fb · Disclosed Nov 13, 2022 · java · python · networkOperationalTomcat_PUT_GUI_EXPThis repository is a graphical JavaFX tool for exploiting CVE-2017-12615, a vulnerability in Apache Tomcat 7.0.0-7.0.79 on Windows that allows arbitrary file upload via the HTTP PUT method. The tool provides a GUI for: - Detecting if a target Tomcat server is vulnerable by checking for PUT support and attempting to upload a test JSP shell. - Uploading a default or custom JSP webshell (default is Godzilla webshell, password: xiaokp) to the server. - Executing arbitrary system commands on the target via the uploaded shell (with password 'xiaokp.456.789'). The main logic is in 'src/cn/xiaokp/Tomcat_PUT_EXP/Controller.java', which handles vulnerability detection, command execution, and webshell upload. The tool uses the 'HttpRequest' Java library for HTTP requests. The endpoints '/exec.jsp' and '/shell.jsp' are used for shell access and command execution. The repository includes Java source, FXML UI definitions, and supporting library code, with the entry point at 'Main.java'. This is an operational exploit with a working payload and a user-friendly interface, suitable for penetration testing of Tomcat servers vulnerable to CVE-2017-12615.xiaokp7 · Disclosed Mar 10, 2023 · java · xml · networkOperationalCVE-2017-12615This repository contains a single-file JSP webshell (1.jsp) and a README.md with usage instructions. The webshell allows remote command execution by passing a 'cmd' parameter via HTTP GET requests. The README demonstrates how to upload the webshell to a target server using curl and provides a sample endpoint (http://34.124.205.159:8080/1.jsp). The exploit is operational and can be used against any web server capable of executing JSP files where arbitrary file upload is possible. The main attack vector is network-based, targeting web servers that process JSP files. No specific CVE is referenced, and the exploit is generic in nature.Fa1c0n35 · Disclosed Nov 7, 2025 · jsp · networkOperationalCVE-2017-12615This repository is a small standalone exploit project for CVE-2017-12615, containing one documentation file (README.md) and one Python exploit script (exploit.py). The README explains the Apache Tomcat arbitrary JSP upload issue affecting Tomcat 7.0.0 through 7.0.79 on Windows when PUT is enabled and DefaultServlet is writable. The Python script is the operational component: it disables TLS warnings, uses requests for HTTP interaction, rich for console output, threading for concurrency and listener handling, and argparse for CLI control. The exploit has two main capabilities. First, it can scan one or more targets for vulnerability by attempting HTTP PUT uploads of temporary JSP files using several path variants, including plain .jsp, trailing slash, %20 suffix, and ::$DATA suffix. It then performs HTTP GET to confirm the uploaded file is retrievable and issues DELETE for cleanup. Second, it can exploit a vulnerable target by generating a JSP reverse shell payload, uploading it to the Tomcat web root, and triggering execution so the target connects back to an attacker-controlled listener. The embedded JSP payload is more than a simple command runner: it creates a socket to the supplied LHOST/LPORT, spawns cmd.exe on Windows or /bin/bash otherwise, and relays stdin/stdout/stderr between the shell process and the socket using Java stream-handling threads. That makes the repository an operational exploit rather than a mere proof of concept. The code appears intended for direct command-line use, with exploit.py as the entry point. The visible code and README are consistent with the claimed vulnerability and do not indicate the repository is fake.K3ysTr0K3R · Disclosed Jul 3, 2026 · python · markdown · network · webOperationalTomcatScanProThis repository is a Python-based exploitation toolkit targeting Apache Tomcat servers. The main script, TomcatScanPro.py, automates detection and exploitation of several vulnerabilities and misconfigurations: 1. CVE-2017-12615: Exploits the HTTP PUT method to upload a JSP webshell using three different path tricks. After upload, it attempts to access and execute the shell to verify remote code execution. 2. CNVD-2020-10487: Exploits the AJP protocol to perform local file inclusion (LFI), by default reading WEB-INF/web.xml, with the ability to customize the file path and success keyword. 3. Weak Password Brute-Force: Attempts to brute-force Tomcat Manager credentials using provided username and password lists. Upon successful login, it uploads a WAR package containing a Godzilla JSP webshell for persistent remote code execution. The tool supports concurrent scanning of multiple targets, configurable via a YAML file. All successful exploitation attempts are logged to success.txt. The payloads are customizable, and the default shell is a Godzilla JSP shell supporting AES-encrypted payloads. The repository includes sample data files for URLs, usernames, and passwords, as well as configuration and requirements files. The tool is operational and can be used for both vulnerability assessment and exploitation of Tomcat servers.lizhianyuguangming · Disclosed Aug 29, 2024 · python · networkPoCCVE-2017-12615-PoCThis repository provides a proof-of-concept (PoC) exploit and a vulnerable environment for CVE-2017-12615, a remote code execution vulnerability in Apache Tomcat. The main exploit is implemented in 'CVE-2017-12615.py', a Python script that uploads a JSP file to a target Tomcat server using an HTTP PUT request. The exploit leverages a misconfiguration (readonly=false) in the Tomcat DefaultServlet, as set in the provided 'web.xml', to allow arbitrary file upload and execution. The repository includes a Dockerfile and docker-compose.yml to set up a vulnerable Tomcat 7.0.79 instance for testing. The README.md provides detailed setup and usage instructions. The exploit's main capability is to achieve remote code execution by uploading and executing a JSP webshell on the target server. Key fingerprintable endpoints include the upload URL (http://[TARGETIP]/[jsp_name]/) and the resulting webshell (http://[TARGETIP]/test.jsp).edyekomu · Disclosed Jun 21, 2025 · python · jsp · networkPoCvulhub-tomcat-cve-2017-12615This is primarily a deliberately vulnerable training environment, with a manual exploitation example rather than a standalone exploit client. Its 32 files include vendored Vulhub application Dockerfiles and English/Chinese walkthroughs, a shell detection check, an Isoloom specification, generated Docker/Kubernetes/VM/cloud deployment assets, CTF metadata, and GitHub validation/publishing workflows. The 15 code-bearing files comprise five shell scripts, seven Terraform modules, one Ruby Vagrantfile, and two Dockerfiles; YAML additionally defines orchestration and CI behavior. app/Dockerfile enables DefaultServlet writes by setting readonly=false. The walkthrough demonstrates PUT /1.jsp/ to bypass direct JSP-upload restrictions through a trailing slash. However, its body is only the literal text 'shell': no executable JSP, command runner, reverse shell, credential theft, or exfiltration implementation is included. checks/put-allowed.sh only checks a version banner and OPTIONS Allow header; it does not prove successful file writing or code execution. The repository is therefore classified as a documented exploitation POC, while its executable security checks are detection-only. The repository labels the issue CVE-2017-12615, but that CVE is associated with Tomcat 7 on Windows; the demonstrated Linux Tomcat 8.5.19 trailing-slash PUT bypass is more consistent with CVE-2017-12617. The reported target ID above preserves the repository's explicit claim rather than silently correcting it. Generated deployment options cover Docker, Kubernetes, Vagrant-backed Docker VMs, Proxmox, and six cloud providers. Docker removes the vulnerable service's default route, while Kubernetes uses egress policies whose enforcement depends on the cluster networking implementation. Local publication defaults to loopback; cloud deployment opens SSH and HTTP to an operator-provided CIDR, and Kubernetes publishes port 8080 through a LoadBalancer. The Internet probe at 1.1.1.1 tests isolation, not attacker communications. Infrastructure cleanup commands are contextual provisioning/CI operations, not evidence of a fake exploit. Isoloom is lab orchestration, not an exploit framework. The original repository URL, analyzed repository ref, and archive byte size were not provided; their fields are left empty or zero. UPSTREAM.md identifies vendored Vulhub source commit 8fd63916f7a8711e2e01dda0d27237e4d6175d38, which is not necessarily the analyzed repository's commit. Analysis is static; no deployment or exploit execution was performed.CyberCTF · Disclosed Oct 8, 2026 · sh · bash · web · networkPoC
Exposure surface

Affected products & vendors

Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.

VendorProductType
Apache Software FoundationTomcatapplication
NetApp7-Mode Transition Toolapplication
NetAppOncommand Balanceapplication
NetAppOncommand Shiftapplication
Red HatEnterprise Linux Desktopoperating_system
Red HatEnterprise Linux Eusoperating_system
Red HatEnterprise Linux Eus Compute Nodeoperating_system
Red HatEnterprise Linux For Ibm Z Systemsoperating_system
Red HatEnterprise Linux For Ibm Z Systems Eusoperating_system
Red HatEnterprise Linux For Power Big Endianoperating_system
Red HatEnterprise Linux For Power Big Endian Eusoperating_system
Red HatEnterprise Linux For Power Little Endianoperating_system
Red HatEnterprise Linux For Power Little Endian Eusoperating_system
Red HatEnterprise Linux For Scientific Computingoperating_system
Red HatEnterprise Linux Serveroperating_system
Red HatEnterprise Linux Server Ausoperating_system
Red HatEnterprise Linux Server For Power Little Endian Update Services For Sap Solutionsoperating_system
Red HatEnterprise Linux Server Tusoperating_system
Red HatEnterprise Linux Server Update Services For Sap Solutionsoperating_system
Red HatEnterprise Linux Workstationoperating_system
Red HatJboss Enterprise Web Serverapplication
Red HatJboss Enterprise Web Server Text-Only Advisoriesapplication
FAQ

Frequently asked questions

Is CVE-2017-12615 exploited in the wild?
Yes. As of Oct 16, 2026, Mallory has reports of exploitation in the wild, and CISA added it to KEV on Mar 25, 2022.
Is there a public exploit for CVE-2017-12615?
Yes. Mallory tracks 11 public exploits or proofs of concept for CVE-2017-12615, the earliest disclosed Sep 25, 2017.
Is there a patch for CVE-2017-12615?
Apply the vendor security update for the affected Tomcat distribution. Apache Tomcat 7.0.81 contains a fix for CVE-2017-12615, but that fix is bypassed by the separate CVE-2017-12617 vulnerability; select an update that addresses both issues.
What products are affected by CVE-2017-12615?
Apache Software Foundation Tomcat, Red Hat Enterprise Linux Desktop, Red Hat Enterprise Linux Eus, Red Hat Enterprise Linux Eus Compute Node, Red Hat Enterprise Linux For Ibm Z Systems, and at least 17 more.
How severe is CVE-2017-12615?
CVE-2017-12615 has a CVSS v3.1 score of 8.1 (High) and an EPSS score of 99.7% (100th percentile) as of Oct 16, 2026.
Activity feed

Recent activity

24 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.

View more in app →
+16 more in the timeline. Sign up to see them
Do you run this?See affected versions in your environment and whether adversaries are exploiting this vulnerability against assets like yours.
Check your exposure
Mallory platform

The version that knows your environment.

This page is what’s public. Mallory adds the parts that aren’t: which of your assets are affected, which adversaries are exploiting it right now, and which detections to deploy tonight.
Exposure mappingQuery your assets running an affected version, and investigate the blast radius.
Threat actor evidenceEvery report linking this CVE to a named adversary.
Associated malware6Malware families linked to this CVE, with evidence and IOCs.
Detection signatures9YARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.
Vendor-by-vendor mappingCross-references every affected SKU, including bundled OEM variants.
Social activity4Community discussion across Reddit, Mastodon, and other social sources.