High severity · published Jul 18, 2022
CVE-2022-33891
Apache Spark shell command injection vulnerability via Spark UI
In wildKEV
8.8
CVSS
93.2%
EPSS
Yes
On KEV
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.
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Attack vector
Network
Complexity
Low
Privileges
Low
User interaction
None
Confidentiality
High
Integrity
High
Availability
High
Scope
Unchanged
Exploitation
Is it being used?
Exploit prediction (EPSS)93.2% · higher than 100% of CVEs
Exploited in the wildYes
CISA KEVListed Mar 7, 2023
Federal remediation dueMar 28, 2023
Ransomware campaign useNot known
Affected products
Which versions
AS
Apache Spark · Apache Software Foundation
3.0.3 and earlier through 3.0.3; 3.1.1 to 3.1.2 through 3.1.2; 3.2.0 to 3.2.1 through 3.2.1 · source: vendor
SP
Spark · Apache
through 3.0.3; 3.1.1 through 3.1.2; 3.2.0 through 3.2.1 · source: NVD, KEV
References
NVD
https://nvd.nist.gov/vuln/detail/CVE-2022-33891
CVE.org
https://www.cve.org/CVERecord?id=CVE-2022-33891
CISA KEV catalogue
https://www.cisa.gov/known-exploited-vulnerabilities-catalog
lists.apache.org
https://lists.apache.org/thread/p847l3kopoo5bjtmxrcwk21xp6tjxqlc
packetstormsecurity.com
http://packetstormsecurity.com/files/168309/Apache-Spark-Unauthenticated-Command-Injection.html
mailing-list
http://www.openwall.com/lists/oss-security/2023/05/02/1
More from Apache Spark
8.8
CVE-2025-54920
Apache Spark: Spark History Server Code Execution Vulnerability
6.1
CVE-2026-32773
Apache Spark: XSS Vulnerability in Spark Web 3.5.4
5.9
CVE-2024-23945
Apache Hive, Apache Spark, Apache Spark: CookieSigner exposes the correct signature when message verification fails
5.5
CVE-2018-11760
When using PySpark , it's possible for a different local user to connect to the Spark application and impersonate the user running the Spark application
5.4
CVE-2022-31777
Apache Spark XSS vulnerability in log viewer UI Javascript
