CVE-2021-21350
Remote Code Execution vulnerability in com.thoughtworks.xstream:xstream

Remote Code Execution No known exploit

What is CVE-2021-21350 About?

This vulnerability allows a remote attacker to execute arbitrary code by manipulating the processed input stream in XStream. Its impact is severe, potentially leading to full system compromise. Exploitation is relatively easy if the default blacklist security framework is relied upon without further whitelisting.

Affected Software

com.thoughtworks.xstream:xstream <1.4.16

Technical Details

The vulnerability in XStream allows for remote code execution through manipulated input streams. It specifically exploits weaknesses in XStream's default blacklist-based security framework. An attacker can craft a malicious input stream containing specific deserialization gadgets that bypass the default blacklist. When XStream processes this stream, it instantiates and invokes arbitrary classes/methods, typically through reflection or other dynamic mechanisms, leading to the execution of attacker-controlled code. This attack vector leverages the inherent dangers of deserializing untrusted data without a strict whitelist of allowed types and objects.

What is the Impact of CVE-2021-21350?

Successful exploitation may allow attackers to achieve arbitrary code execution, gain full control over the compromised system, or cause data corruption and service disruption.

What is the Exploitability of CVE-2021-21350?

Exploitation is of moderate complexity, requiring knowledge of XStream's deserialization process and potential gadget chains. No authentication is typically needed as the attack targets the input processing functionality. There are no specific privilege requirements on the target for the initial execution. This is a remote vulnerability, allowing an attacker to send a malicious input stream over the network. A key prerequisite is that the application uses XStream and relies on its default blacklist for security, without implementing a stricter whitelist. The likelihood of exploitation increases when untrusted input is fed directly into the XStream deserializer.

What are the Known Public Exploits?

PoC Author Link Commentary
No known exploits

What are the Available Fixes for CVE-2021-21350?

Available Upgrade Options

  • com.thoughtworks.xstream:xstream
    • <1.4.16 → Upgrade to 1.4.16

Struggling with dependency upgrades?

See how Resolved Security's drop-in replacements make it simple.

Book a demo

Additional Resources

What are Similar Vulnerabilities to CVE-2021-21350?

Similar Vulnerabilities: CVE-2021-39153 , CVE-2021-39151 , CVE-2020-26217 , CVE-2020-26258 , CVE-2017-7957