CVE-2021-21345XStream is vulnerable to a Remote Command Execution attack
- 5.8MediumCVSS base score
- 72.3%Exploitation in 30 daysEPSS · top 0.6% of all CVEs
- NoKnown exploitednot in CISA's KEV catalog
- 1Public exploitsMetasploit, Nuclei and Exploit-DB
Description
XStream is a Java library to serialize objects to XML and back again. In XStream before version 1.4.16, there is a vulnerability which may allow a remote attacker who has sufficient rights to execute commands of the host only by manipulating the processed input stream. No user is affected, who followed the recommendation to setup XStream's security framework with a whitelist limited to the minimal required types. If you rely on XStream's default blacklist of the Security Framework, you will have to use at least version 1.4.16.
Public exploit
An exploit or proof of concept is public: anyone can try it against an unpatched system. The public collections list a Nuclei template for it.
Show the exploits1
Nuclei templates1 template
- XStream < 1.4.16 - Remote Code Execution (Nuclei template) (opens in a new tab)
http/cves/2021/CVE-2021-21345.yamlSeverity critical
Modules, templates and exploits as listed by the Metasploit Framework (BSD-3-Clause), ProjectDiscovery's Nuclei templates (MIT) and the Exploit Database (GPLv2), read once a day. Where the data comes from
Timeline
ID reserved
By GitHub_M
- 3 months later
· 3 months later
Published
- 6 years later
· 6 years later
Record updated
Changes after publication (a new score, a public exploit, EPSS crossing 1, 10 or 50 %, leaving KEV) are kept since November 2026; earlier ones are not known.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| GitHub_MCNA (assigner) | 3.1 | Medium5.8 | CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:N/I:H/A:N |
| NVDNVD · Analyzed | 3.1 | Critical9.9 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H |
- EPSS (exploitation in 30 days)
- 72.3% · top 0.6% of all CVEs (17 Nov 2026)
- CISA SSVC
- Exploitation: none · Automatable: no · Technical impact: total
The list uses the assigner's score when there is one, then CISA's, then NVD's: Medium 5.8.
Affected products
Affected packages
From reviewed advisories of the GitHub Advisory Database.
- Mavencom.thoughtworks.xstream:xstreamGHSA-hwpc-8xqv-jvj4 (opens in a new tab)
References
References16
- https://x-stream.github.io/security.html#workaround (opens in a new tab)x_refsource_MISCx_transferred
- http://x-stream.github.io/changes.html#1.4.16 (opens in a new tab)x_refsource_MISCx_transferred
- https://github.com/x-stream/xstream/security/advisories/GHSA-hwpc-8xqv-jvj4 (opens in a new tab)x_refsource_CONFIRMx_transferred
- https://x-stream.github.io/CVE-2021-21345.html (opens in a new tab)x_refsource_MISCx_transferred
- [debian-lts-announce] 20210403 [SECURITY] [DLA 2616-1] libxstream-java security update (opens in a new tab)mailing-listx_refsource_MLISTx_transferred
- [jmeter-dev] 20210406 [GitHub] [jmeter] sseide opened a new pull request #655: update x-stream to 1.4.16 (from 1.4.15) (opens in a new tab)mailing-listx_refsource_MLISTx_transferred
- [activemq-users] 20210427 Release date for ActiveMQ v5.16.2 to fix CVEs (opens in a new tab)mailing-listx_refsource_MLISTx_transferred
- https://www.oracle.com/security-alerts/cpuApr2021.html (opens in a new tab)x_refsource_MISCx_transferred
- https://security.netapp.com/advisory/ntap-20210430-0002/ (opens in a new tab)x_refsource_CONFIRMx_transferred
- https://www.oracle.com//security-alerts/cpujul2021.html (opens in a new tab)x_refsource_MISCx_transferred
- FEDORA-2021-fbad11014a (opens in a new tab)vendor-advisoryx_refsource_FEDORAx_transferred
- FEDORA-2021-d894ca87dc (opens in a new tab)vendor-advisoryx_refsource_FEDORAx_transferred
- https://www.oracle.com/security-alerts/cpuoct2021.html (opens in a new tab)x_refsource_MISCx_transferred
- FEDORA-2021-5e376c0ed9 (opens in a new tab)vendor-advisoryx_refsource_FEDORAx_transferred
- DSA-5004 (opens in a new tab)vendor-advisoryx_refsource_DEBIANx_transferred
- https://www.oracle.com/security-alerts/cpujan2022.html (opens in a new tab)x_refsource_MISCx_transferred
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- EUVD EUVD-2021-0674 (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisory GHSA-hwpc-8xqv-jvj4 (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://cveledger.app/cve/CVE-2021-21345)Record last updated .