Apache Software Foundation Apache Tomcat
Apache Tomcat Remote Code Execution Vulnerability
When running Apache Tomcat versions 9.0.0.M1 to 9.0.0, 8.5.0 to 8.5.22, 8.0.0.RC1 to 8.0.46 and 7.0.0 to 7.0.81 with HTTP PUTs enabled (e.g. via setting the readonly initialisation parameter of the Default servlet to false) it was possible to upload a JSP file to the server via a specially crafted request. This JSP could then be requested and any code it contained would be executed by the server.
Affected versions and mitigation
From the CVE record, GitHub Security Advisories and the vendor's references.Affected
- >= 9.0.0.M1, < 9.0.1
Fixed in 9.0.1
from GitHub Security Advisory GHSA-xjgh-84hx-56c5
- >= 8.5.0, < 8.5.23
Fixed in 8.5.23
from GitHub Security Advisory GHSA-xjgh-84hx-56c5
- >= 8.0.0-RC1, < 8.0.47
Fixed in 8.0.47
from GitHub Security Advisory GHSA-xjgh-84hx-56c5
- >= 7.0.0, < 7.0.82
Fixed in 7.0.82
from GitHub Security Advisory GHSA-xjgh-84hx-56c5
- >= 9.0.0.M1, < 9.0.1
Fixed in 9.0.1
from GitHub Security Advisory GHSA-xjgh-84hx-56c5
- >= 8.5.0, < 8.5.23
Fixed in 8.5.23
from GitHub Security Advisory GHSA-xjgh-84hx-56c5
- >= 8.0.0-RC1, < 8.0.47
Fixed in 8.0.47
from GitHub Security Advisory GHSA-xjgh-84hx-56c5
- >= 7.0.0, < 7.0.82
Fixed in 7.0.82
from GitHub Security Advisory GHSA-xjgh-84hx-56c5
Mitigation
Upgrade org.apache.tomcat:tomcat-catalina to 9.0.1 or later.
Upgrade org.apache.tomcat:tomcat-catalina to 8.5.23 or later.
Upgrade org.apache.tomcat:tomcat-catalina to 8.0.47 or later.
Upgrade org.apache.tomcat:tomcat-catalina to 7.0.82 or later.
Upgrade org.apache.tomcat.embed:tomcat-embed-core to 9.0.1 or later.
Upgrade org.apache.tomcat.embed:tomcat-embed-core to 8.5.23 or later.
Upgrade org.apache.tomcat.embed:tomcat-embed-core to 8.0.47 or later.
Upgrade org.apache.tomcat.embed:tomcat-embed-core to 7.0.82 or later.
Timeline
Days relative to CVE publicationFirst public PoC 2.4 days after publication; added to CISA KEV 4.5 years after publication. First PoC: cyberheartmi9/CVE-2017-12617 (created 5 Oct 2017, found by us: backfilled).
PoC repositories
Found on GitHub.13 PoCs · 2 pending · 1 not a PoC · 2 suspicious or fake
PoCs 13
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| cyberheartmi9/CVE-2017-12617 | 5 Oct 2017 +2.4 d | 401 | PoC |
| devcoinfet/CVE-2017-12617 | 9 Feb 2018 +128 d | 0 | PoC |
| qiantu88/CVE-2017-12617 | 19 Dec 2018 +1.2 y | 0 | PoC |
| ygouzerh/CVE-2017-12617 | 14 Jan 2019 +1.3 y | 2 | PoC |
| scxiaotan1/Docker | 17 Apr 2020 +2.5 y | 0 | PoC via PoC Index |
| tyranteye666/tomcat-cve-2017-12617 | 4 Feb 2021 +3.3 y | 1 | PoC |
| 3ndG4me/ghostcat | 16 Aug 2021 +3.9 y | 6 | PoC |
| LongWayHomie/CVE-2017-12617 | 10 Dec 2021 +4.2 y | 6 | PoC |
| scirusvulgaris/CVE-2017-12617 | 28 Jun 2024 +6.7 y | 0 | PoC |
| yZ1337/CVE-2017-12617 | 4 Jul 2024 +6.8 y | 0 | PoC |
| yZee00/CVE-2017-12617 | 4 Jul 2024 +6.8 y | 0 | PoC |
| yZeetje/CVE-2017-12617 | 4 Jul 2024 +6.8 y | 0 | PoC |
| DevaDJ/CVE-2017-12617 | 13 Dec 2024 +7.2 y | 0 | PoC |
Pending 2
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| lem0n817/CVE-2017-12617-POC | 4 Sep 2026 +8.9 y | 0 | Pending · repository unavailable (HTTP 404) |
| K3ysTr0K3R/CVE-2017-12617-EXPLOIT | unknown | 0 | Pending · repository unavailable (HTTP 404) |
Not a PoC 1
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| zi0Black/POC-CVE-2017-12615-or-CVE-2017-12717 | 6 Oct 2017 +3.3 d | 6 | Not a PoC · unrelated |
Suspicious or fake 2
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| Kaizhe/attacker | 2 Oct 2019 +2.0 y | 1 | Fake |
| jptr218/tc_hack | 27 Jul 2021 +3.8 y | 1 | Suspicious · score 75
Why suspicious
|
Only PoCs count toward the first-PoC date and the characteristics below. Suspicious repositories (score ≥ 50) never count. Do not run PoC code from unknown sources.
Other public exploits
Exploit-DB, Metasploit and nuclei count as public PoCs. Exploit-tagged references from the CVE record and NVD are links only. None of these are analysed by us.| Source | Title | Published | Found by us |
|---|---|---|---|
| CVE record (tagged exploit) | 42966 | unknown | 14 Nov 2026 |
| CVE record (tagged exploit) | 43008 | unknown | 14 Nov 2026 |
| Exploit-DB | Apache Tomcat < 9.0.1 (Beta) / < 8.5.23 / < 8.0.47 / < 7.0.8 - JSP Upload Bypass / Remote Code Execution (2) | 9 Oct 2017 | 14 Nov 2026 |
| Exploit-DB | Tomcat - Remote Code Execution via JSP Upload Bypass (Metasploit) | 17 Oct 2017 | 14 Nov 2026 |
| Metasploit | Metasploit exploit: Tomcat RCE via JSP Upload Bypass (exploit/multi/http/tomcat_jsp_upload_bypass) | 9 Oct 2017 | 14 Nov 2026 |
| nuclei template | nuclei template: Apache Tomcat - Remote Code Execution | 15 Jun 2023 | 14 Nov 2026 |
PoC characteristics
What to hunt for in your logs · from 13 PoC reposGET /{var}
- Query
cmd=- PoC User-Agent
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.95 Safari/537.36- Seen in
- 9 repos: DevaDJ/CVE-2017-12617, cyberheartmi9/CVE-2017-12617, qiantu88/CVE-2017-12617, scirusvulgaris/CVE-2017-12617, scxiaotan1/Docker, tyranteye666/tomcat-cve-2017-12617, yZ1337/CVE-2017-12617, yZee00/CVE-2017-12617, yZeetje/CVE-2017-12617
- Evidence
- DevaDJ/CVE-2017-12617/CVE-2017-12617.py:44 DevaDJ/CVE-2017-12617/CVE-2017-12617.py:88 cyberheartmi9/CVE-2017-12617/tomcat-cve-2017-12617.py:65 cyberheartmi9/CVE-2017-12617/tomcat-cve-2017-12617.py:115 qiantu88/CVE-2017-12617/tomcat-cve-2017-12617.py:65 qiantu88/CVE-2017-12617/tomcat-cve-2017-12617.py:115
GET /solr/te1/config
- Body markers
Host: 172.17.0.3:8983- Seen in
- 1 repo: scxiaotan1/Docker
- Evidence
- scxiaotan1/Docker/CVE-2019-0193/README.md:18
GET /revshell.jsp
- Seen in
- 1 repo: LongWayHomie/CVE-2017-12617
- Evidence
- LongWayHomie/CVE-2017-12617/CVE-2017-12617.py:123
PUT //revshell.jsp/
- Key headers
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8Accept-Language: de,en-US;q=0.7,en;q=0.3Cache-Control: max-age=0Upgrade-Insecure-Requests: 1- Content-Type
text/html;charset=UTF8- PoC User-Agent
Mozarella/5.0 (X11; Ubuntu; Linux x86_64; rv:88.0) Gecko/20100101 Firefox/88.0- Seen in
- 1 repo: LongWayHomie/CVE-2017-12617
- Evidence
- LongWayHomie/CVE-2017-12617/CVE-2017-12617.py:107
PUT /web_shell.jsp/
- Body markers
@-=inapplication/x-www-form-urlencoded- Ports
- 8080
- Seen in
- 1 repo: ygouzerh/CVE-2017-12617
- Evidence
- ygouzerh/CVE-2017-12617/attack.sh:2
Regex
Generated from PoC characteristics; not yet reviewed. Matches the request path and query.
(?i)^/[^/?#]*\?(?:.*&)?cmd=
(?i)^/solr/te1/config(?:[?#].*)?$
(?i)^/revshell\.jsp(?:[?#].*)?$
(?i)^//revshell\.jsp/(?:[?#].*)?$
(?i)^/web_shell\.jsp/(?:[?#].*)?$
Suricata
Template generated from PoC characteristics. Review before deploying.
alert http any any -> $HOME_NET any (msg:"GG PoC-Monitor CVE-2017-12617 Apache Software Foundation Apache Tomcat exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"cmd="; reference:url,poc.griffinguard.io/cve/CVE-2017-12617; classtype:web-application-attack; sid:9803880; rev:1;)
alert http any any -> $HOME_NET any (msg:"GG PoC-Monitor CVE-2017-12617 Apache Software Foundation Apache Tomcat exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"/solr/te1/config"; http.request_body; content:"Host: 172.17.0.3:8983"; reference:url,poc.griffinguard.io/cve/CVE-2017-12617; classtype:web-application-attack; sid:9538425; rev:1;)
alert http any any -> $HOME_NET any (msg:"GG PoC-Monitor CVE-2017-12617 Apache Software Foundation Apache Tomcat exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"/revshell.jsp"; reference:url,poc.griffinguard.io/cve/CVE-2017-12617; classtype:web-application-attack; sid:9407881; rev:1;)
alert http any any -> $HOME_NET any (msg:"GG PoC-Monitor CVE-2017-12617 Apache Software Foundation Apache Tomcat exploit attempt"; flow:established,to_server; http.method; content:"PUT"; http.uri; content:"//revshell.jsp/"; http.header; content:"Accept: text/html,application/xhtml+xml,application/xml|3b|q=0.9,image/webp,*/*|3b|q=0.8"; nocase; http.header; content:"Accept-Language: de,en-US|3b|q=0.7,en|3b|q=0.3"; nocase; http.header; content:"Cache-Control: max-age=0"; nocase; http.header; content:"Upgrade-Insecure-Requests: 1"; nocase; reference:url,poc.griffinguard.io/cve/CVE-2017-12617; classtype:web-application-attack; sid:9028134; rev:1;)
alert http any any -> $HOME_NET [8080] (msg:"GG PoC-Monitor CVE-2017-12617 Apache Software Foundation Apache Tomcat exploit attempt"; flow:established,to_server; http.method; content:"PUT"; http.uri; content:"/web_shell.jsp/"; http.request_body; content:"@-="; reference:url,poc.griffinguard.io/cve/CVE-2017-12617; classtype:web-application-attack; sid:9500035; rev:1;)
Sigma
Template generated from PoC characteristics. Review before deploying.
title: Apache Software Foundation Apache Tomcat exploit attempt (CVE-2017-12617)
id: gg-pocmon-cve-2017-12617-9803880
status: experimental
description: Request pattern taken from public PoCs for CVE-2017-12617. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2017-12617
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-query|contains|all:
- 'cmd='
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2017.12617
title: Apache Software Foundation Apache Tomcat exploit attempt (CVE-2017-12617)
id: gg-pocmon-cve-2017-12617-9538425
status: experimental
description: Request pattern taken from public PoCs for CVE-2017-12617. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2017-12617
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-stem|contains|all:
- '/solr/te1/config'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2017.12617
title: Apache Software Foundation Apache Tomcat exploit attempt (CVE-2017-12617)
id: gg-pocmon-cve-2017-12617-9407881
status: experimental
description: Request pattern taken from public PoCs for CVE-2017-12617. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2017-12617
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-stem|contains|all:
- '/revshell.jsp'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2017.12617
title: Apache Software Foundation Apache Tomcat exploit attempt (CVE-2017-12617)
id: gg-pocmon-cve-2017-12617-9028134
status: experimental
description: Request pattern taken from public PoCs for CVE-2017-12617. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2017-12617
logsource:
category: webserver
detection:
selection:
cs-method: PUT
cs-uri-stem|contains|all:
- '//revshell.jsp/'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2017.12617
title: Apache Software Foundation Apache Tomcat exploit attempt (CVE-2017-12617)
id: gg-pocmon-cve-2017-12617-9500035
status: experimental
description: Request pattern taken from public PoCs for CVE-2017-12617. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2017-12617
logsource:
category: webserver
detection:
selection:
cs-method: PUT
cs-uri-stem|contains|all:
- '/web_shell.jsp/'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: high
tags:
- attack.initial_access
- attack.t1190
- cve.2017.12617