CVE-2022-25168 | Command injection in org.apache.hadoop.fs.FileUtil.unTarUsingTar

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).

Published: 2022-08-04 Last update: 2024-11-21 Assigner: [email protected] Source: [email protected]

Conclusion & alert: CVE-2022-25168 is rated High Risk (69.7/100): CVSS Critical severity, with medium exploitation likelihood (EPSS 3.01%). Mandatory action: High exploitation likelihood—assess exposure and prioritize remediation.

Risk is dynamic; we continuously reassess and refresh what is shown on this page as upstream context changes.

Exploit prediction scoring system (EPSS) score for CVE-2022-25168

EPSS lead: Daily EPSS estimates relative likelihood of exploitation; percentile ranks this CVE among scored vulnerabilities (higher = more severe relative rank).

# Date Old EPSS score New EPSS score Delta (New - Old)
1 2026-01-11 2.67% 3.01% +0.34%
2 2025-12-23 2.84% 2.67% -0.17%
3 2025-12-05 2.84%

Full EPSS history (26 records total)

Common vulnerability scoring system (CVSS) metrics for CVE-2022-25168

CVSS metrics for this CVE.

Base score Version Severity Vector Exploitability Impact Score source
9.8 3.1 CRITICAL
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H Click to expand
Attack vector (AV:N)
Could be attacked over the internet or any normal routed network—not just someone sitting at the machine.
Attack complexity (AC:L)
Once they can reach the bug, pulling it off is straightforward—no weird race conditions or rare setup.
Privileges required (PR:N)
No account or special rights needed—anonymous or random user is enough.
User interaction (UI:N)
Nobody has to click “OK” or open a trap file; it can work without a victim helping.
Scope (S:U)
Damage stays in the same “trust bubble” as the broken component—no big spill into unrelated systems.
Confidentiality (C:H)
Serious risk that confidential data gets exposed in a big way.
Integrity (I:H)
They could widely tamper with or forge data—trust in the data is badly hurt.
Availability (A:H)
Could take the service down hard or make it unusable for people who depend on it.
3.9 5.9 [email protected]

Weakness enumeration for CVE-2022-25168

GitHub Security Advisory for CVE-2022-25168

GHSA-8wm5-8h9c-47pc · Severity: critical · Ecosystem: maven — Apache Hadoop argument injection vulnerability

OS Trackers for CVE-2022-25168

vendor priority summary link
redhat high https://access.redhat.com/security/cve/CVE-2022-25168

Affected software / configurations for CVE-2022-25168

Vendor Product Version Raw CPE
apache hadoop >= 2.0.0, <= 2.10.1 cpe:2.3:a:apache:hadoop:*:*:*:*:*:*:*:*
apache hadoop >= 3.0.0, <= 3.2.3 cpe:2.3:a:apache:hadoop:*:*:*:*:*:*:*:*
apache hadoop >= 3.3.0, <= 3.3.2 cpe:2.3:a:apache:hadoop:*:*:*:*:*:*:*:*

References for CVE-2022-25168

cvelogic Threat Intelligence