Exploit database

Vulnerability

CVE-2022-33891

Apache Spark shell command injection vulnerability via Spark UI

Vulnerability details

Score
8.8
Severity
high

CVSS 3.1 · CISA-ADP

Vector string

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Description

The Apache Spark UI offers the possibility to enable ACLs via the configuration option spark.acls.enable. With an authentication filter, this checks whether a user has access permissions to view or modify the application. If ACLs are enabled, a code path in HttpSecurityFilter can allow someone to perform impersonation by providing an arbitrary user name. A malicious user might then be able to reach a permission check function that will ultimately build a Unix shell command based on their input, and execute it. This will result in arbitrary shell command execution as the user Spark is currently running as. This affects Apache Spark versions 3.0.3 and earlier, versions 3.1.1 to 3.1.2, and versions 3.2.0 to 3.2.1.

CVE Program

Exploit source choices

12 sources
Apache Spark Unauthenticated Command Injection RCE
MSF-linux--http--apache_spark_rce_cve_2022_33891MetasploitLinux,Unix / remotePreferred

This module exploits an unauthenticated command injection vulnerability in Apache Spark. Successful exploitation results in remote code execution under the context of the Spark application user. The command injection occurs because Spark checks the group membership of the user passed in the ?doAs parameter by using a raw Linux command. It is triggered by a non-default setting called spark.acls.enable. This configuration setting spark.acls.enable should be set true in the Spark configuration to make the application vulnerable for this attack. Apache Spark versions 3.0.3 and earlier, versions 3.1.1 to 3.1.2, and versions 3.2.0 to 3.2.1 are affected by this vulnerability.

2022-07-18apache_spark_rce_cve_2022_33891.rb
w01fh4cker/serein
GH-819c2509bb770e4f9c276053dd6ca8efGitHubUnofficial GitHub source

【懒人神器】一款图形化、批量采集url、批量对采集的url进行各种nday检测的工具。可用于src挖掘、cnvd挖掘、0day利用、打造自己的武器库等场景。可以批量利用Actively Exploited Atlassian Confluence 0Day CVE-2022-26134和DedeCMS v5.7.87 SQL注入 CVE-2022-23337。

2022-05-3157 files · 1,244 stars
arpsyndicate/kenzer-templates
GH-e5a0867366963da7a3617cf6f32fda4bGitHubUnofficial GitHub source

essential templates for kenzer [DEPRECATED]

2020-09-185,308 files · 118 stars
huskyhacks/cve-2022-33891
GH-b16e8bb09afabdda0520c615979ebc5eGitHubUnofficial GitHub source

Apache Spark Shell Command Injection Vulnerability

2022-07-195 files · 88 stars
w01fh4cker/cve-2022-33891
GH-a11bfc21ae64844d119c3242f4025945GitHubUnofficial GitHub source

cve-2022-33891-poc

2022-07-182 files · 51 stars
amoloht/cve-2022-33891
GH-164f1dbdf1732c4a2ab94bccc6073137GitHubUnofficial GitHub source

「💥」CVE-2022-33891 - Apache Spark Command Injection

2022-07-303 files · 24 stars
akbartrilaksana/cve-2022-33891
GH-3fa2c5a3080f2baea41fd5777af5769cGitHubUnofficial GitHub source

akbartrilaksana/cve-2022-33891 source repository

2022-07-205 files · 3 stars
k3ystr0k3r/cve-2022-33891-exploit
GH-69af5f539928f6f910357c6ab047c9b1GitHubUnofficial GitHub source

A PoC exploit for CVE-2022-33891 - Apache Spark UI Remote Code Execution (RCE)

2024-02-222 files · 2 stars
devengpk/apache-zero-days
GH-27cd74c17766ffb6bd0eb36162b82ff5GitHubUnofficial GitHub source

devengpk/apache-zero-days source repository

2023-01-055 files · 1 stars
drlinuxofficial/cve-2022-33891
GH-4bd9f7644a2433e841bd75766a0374f7GitHubUnofficial GitHub source

CVE-2022-33891 Exploit For Apache Spark

2022-08-133 files · 1 stars
asepsaepdin/cve-2022-33891
GH-4af6b1bf31ec817177e3be73ee5f19ecGitHubUnofficial GitHub source

asepsaepdin/cve-2022-33891 source repository

2025-01-304 files · 0 stars
d4n-sec/d4n-sec.github.io
GH-a977c770ad0cb70a8725a440ce0aeba7GitHubUnofficial GitHub source

Generated personal blog

2026-11-06385 files · 0 stars