CVE-2022-25168 json
Command injection in org.apache.hadoop.fs.FileUtil.unTarUsingTar
published 2022-08-04 4 y ago modified 2026-06-17 4 mo ago also GHSA-8wm5-8h9c-47pc , EUVD-2022-6521
- cvss
- 9.8
- version 3.1, NVD
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 4.6%
- EPSS 4.6% chance of exploitation in 30 days, percentile 91%
- public exploits
- 0
- none known
Summary
Apache Hadoop's FileUtil.unTar(File, File) API does not escape the input file name before being passed to the shell. An attacker can inject arbitrary commands. This is only used in Hadoop 3.3 InMemoryAliasMap.completeBootstrapTransfer, which is only ever run by a local user. It has been used in Hadoop 2.x for yarn localization, which does enable remote code execution. It is used in Apache Spark, from the SQL command ADD ARCHIVE. As the ADD ARCHIVE command adds new binaries to the classpath, being able to execute shell scripts does not confer new permissions to the caller. SPARK-38305. "Check existence of file before untarring/zipping", which is included in 3.3.0, 3.1.4, 3.2.2, prevents shell commands being executed, regardless of which version of the hadoop libraries are in use. Users should upgrade to Apache Hadoop 2.10.2, 3.2.4, 3.3.3 or upper (including HADOOP-18136).
Patch / fix
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2022-25168 updated cvss 9.8
hadoop: Command injection in org.apache.hadoop.fs.FileUtil.unTarUsingTar
-
Red Hat Integration Camel K 1 hadoop hadoopaffected: no fix available “Fix deferred”
-
Red Hat Integration Data Virtualisation Operator hadoop hadoop Red Hat JBoss Data Grid 7 hadoop hadoop Red Hat JBoss Data Virtualization 6 hadoop hadoop Red Hat JBoss Fuse 6 hadoop hadoop Red Hat JBoss Fuse Service Works 6 hadoop hadoop Red Hat JBoss Operations Network 3 hadoop hadoopaffected: no fix planned “Out of support scope”
-
Red Hat OpenShift Container Platform 4 openshift4/ose-metering-hadoopaffected: no fix available
-
Red Hat A-MQ Clients 2 hadoop hadoop Red Hat Advanced Cluster Management for Kubernetes 2 rhacm2/volsync-mover-rclone-rhel8 Red Hat AMQ Broker 7 hadoop hadoop Red Hat Data Grid 8 hadoop hadoop Red Hat Fuse 7 hadoop hadoop Red Hat Integration Camel Quarkus 1 hadoop hadoopnot affected: vulnerable code not present
+3 more productsfewer
Red Hat JBoss Enterprise Application Platform 7 hadoop-core Red Hat JBoss Enterprise Application Platform Expansion Pack hadoop hadoop Red Hat streams for Apache Kafka hadoop hadoop
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
Exploit prediction
4.59% chance of exploitation in the next 30 days, higher than 91% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| NVD | 3.1 | 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| GitHub | 3.1 | 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| maven | org.apache.hadoop:hadoop-common | >=2.0.0, <2.10.2 >=3.0.0-alpha, <3.2.4 >=3.3.0, <3.3.3 |
2.10.2 3.2.4 3.3.3 |
Affected products
- Apache Software Foundation Apache Hadoop
Classification
References
-
github.com
/apache/hadoop/commit/cae749b076f35f0be13a926ee8cfbb7ce4402746
web
-
lists.apache.org
/thread/mxqnb39jfrwgs3j6phwvlrfq4mlox130
web, mailing-list, vendor-advisory
-
security.netapp.com
/advisory/ntap-20220915-0007/
third-party-advisory
-
nvd.nist.gov
/vuln/detail/CVE-2022-25168
advisory
-
github.com
/apache/hadoop
package
-
security.netapp.com
/advisory/ntap-20220915-0007
web
Sources
- CVE List CVE-2022-25168
- GitHub Advisory GHSA-8wm5-8h9c-47pc
- NVD CVE-2022-25168
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.