CVE-2022-25168CWE-78

Command injection in org.apache.hadoop.fs.FileUtil.unTarUsingTar

published August 4, 2022

CVSS
—
EPSS
5%
Percentile
91.6
In the wild
Unconfirmed
What it is

⚡ A sneaky command injection vulnerability in Apache Hadoop could let an attacker run arbitrary commands just by crafting the right file name! Think of it like a restaurant that doesn't double-check orders before serving them. If a server just hands over the dish without asking for clarification, a mischievous diner could slip in ingredients that should never be there, leading to a chaotic kitchen! If an attacker manages to exploit this vulnerability, they could execute arbitrary shell commands on the system, potentially gaining unauthorized access to sensitive data or compromising the entire environment. It's like giving someone the keys to the kitchen because you trusted their order without checking!

Put simply

Think of it like a restaurant that doesn't double-check orders before serving them. If a server just hands over the dish without asking for clarification, a mischievous diner could slip in ingredients that should never be there, leading to a chaotic kitchen! The issue arises in Apache Hadoop's FileUtil.unTar(File, File) API, which fails to escape the input file name before it's passed to the shell. This oversight allows an attacker to inject their commands, especially concerning with the ADD ARCHIVE command in Apache Spark, leading to possible remote code execution in earlier Hadoop versions.

What to do

If an attacker manages to exploit this vulnerability, they could execute arbitrary shell commands on the system, potentially gaining unauthorized access to sensitive data or compromising the entire environment. It's like giving someone the keys to the kitchen because you trusted their order without checking! To protect your systems, it's crucial to upgrade to Apache Hadoop versions 2.10.2, 3.2.4, or 3.3.3 and above. Additionally, ensure you check file existence before untarring or zipping to prevent command execution from untrusted inputs. Don't wait—get those updates rolling! You've got this! Follow these steps, and you'll be on your way to securing your Hadoop environment like a pro! 🛡️

The record
Technical detail
CVSS
Not scored
CVSS v4.0
Not supplied
EPSS
0.04587 · 91.6th percentile
Weakness
CWE-78 · Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')
Published
2022-08-04T14:30Z
EPSS history
Timeline
  • 04 AUG 14:30Z
    Command injection in org.apache.hadoop.fs.FileUtil.unTarUsingTar
    cvelistv5