CVE-2019-10173: Deserialization of Untrusted Data and Code Injection in xstream

Summary

26/07/2019
Yes i
Critical
9.8

CVE-2019-10173: Deserialization of Untrusted Data and Code Injection in xstream. Affects com.thoughtworks.xstream:xstream versions < 1.4.11. Fixed in 1.4.11. How to fix ↓

Also tracked for

The same CVE-2019-10173 is tracked separately for each ecosystem and vendor. Its fix information is the same; the package and affected versions differ.

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Sponsored Devnack Mobile apps built by Devnack Design, build and launch iOS and Android apps with a senior product team. From idea to store release Start a project

Background

The package under scrutiny is com.thoughtworks.xstream:xstream, which is a Java library used for serializing and deserializing Java objects to XML and other supported formats. It provides a simple API for converting Java objects to XML and vice versa. This vulnerability affects versions before 1.4.11 of the xstream API. The vulnerability allows for the deserialization of untrusted data, which can lead to code injection and the execution of arbitrary shell commands.

Vulnerability Detail

The vulnerability in xstream API version 1.4.10 before 1.4.11 is a regression of a previous deserialization flaw (CVE-2013-7285). If the security framework has not been initialized, an attacker can exploit this vulnerability by unmarshalling XML or any supported format, such as JSON, to run arbitrary shell commands. This can result in unauthorized access, data manipulation, and potential system compromise.

How To Fix

Latest published version: 1.4.21 as of 22 Oct 2026

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

1.4.11

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

If upgrading to the fixed version is not immediately feasible, a workaround is to initialize the security framework before unmarshalling any data. This can be done by explicitly calling the appropriate security framework initialization method in your code. Here is an example in Java using the XStream class:

import com.thoughtworks.xstream.XStream;
import com.thoughtworks.xstream.security.NullPermission;

public class XStreamExample {
    public static void main(String[] args) {
        XStream xstream = new XStream();
        xstream.addPermission(NullPermission.NULL);
        // Rest of the code
    }
}

Conclusion

In conclusion, the xstream API version 1.4.10 before 1.4.11 is vulnerable to deserialization of untrusted data and code injection. This can be exploited by an attacker to run arbitrary shell commands. It is crucial to upgrade to version 1.4.11 or later to mitigate this vulnerability. If immediate upgrade is not possible, ensure to initialize the security framework before unmarshalling any data. For further support on vulnerability remediation, contact DevNack.com.

See every vulnerability recorded for com.thoughtworks.xstream:xstream →

Share this vulnerability

FAQ

xstream is a Java library used for serializing and deserializing Java objects to XML and other supported formats. It provides a simple API for converting Java objects to XML and vice versa.

This vulnerability allows for the deserialization of untrusted data, which can lead to code injection and the execution of arbitrary shell commands. It can result in unauthorized access, data manipulation, and potential system compromise.

Versions before 1.4.11 of the xstream API are affected by this vulnerability.

Yes, this vulnerability is a regression of a previous deserialization flaw (CVE-2013-7285).

To fix this vulnerability, it is recommended to upgrade to xstream API version 1.4.11 or later. Update the package in your project's dependencies to the fixed version.

Related vulnerabilities

Recent vulnerabilities recorded for com.thoughtworks.xstream:xstream.

How To Fix

Latest published version: 1.4.21 as of 22 Oct 2026

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

1.4.11

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback