CRITICAL 9.8

CVE-2022-26612

Path traversal in Hadoop

Description

In Apache Hadoop, The unTar function uses unTarUsingJava function on Windows and the built-in tar utility on Unix and other OSes. As a result, a TAR entry may create a symlink under the expected extraction directory which points to an external directory. A subsequent TAR entry may extract an arbitrary file into the external directory using the symlink name. This however would be caught by the same targetDirPath check on Unix because of the getCanonicalPath call. However on Windows, getCanonicalPath doesn't resolve symbolic links, which bypasses the check. unpackEntries during TAR extraction follows symbolic links which allows writing outside expected base directory on Windows. This was addressed in Apache Hadoop 2.10.2, 3.2.3, 3.3.3, and 3.4.0.

Affected Maven artifacts (1)

ArtifactAffected versionsFixed in
org.apache.hadoop » hadoop-common
< 2.10.2>= 3.2.0, < 3.2.3>= 3.3.0, < 3.3.3
2.10.2, 3.2.3, 3.3.3

Blast radius

1affected artifacts
2,823affected versions
8,514dependent artifacts (est.)
868,684dependent versions

65% of the dependent artifacts (5,562) still pull an affected version in their latest release.

DepthDependent versions
Direct
267,203
2 hops
264,940
3 hops
188,959
4 hops
69,785
5 hops
53,480
6 hops
24,317

Most used dependents

Computed from the dependency graph of build 20261124.0621 (compile and runtime scopes, nearest version wins). Exclusions and dependency management in consuming projects are not applied, so dependents are potentially affected. When several artifacts are affected, a dependent version that pulls more than one of them is counted once per artifact.