CVE-2025-66249
Java vulnerability analysis and mitigation

Overview

CVE-2025-66249 is a path traversal vulnerability (CWE-22) in Apache Livy that allows authenticated attackers with low privileges to bypass directory restrictions and access files outside the intended whitelist directories. It affects Apache Livy versions 0.3.0-incubating through 0.8.x (before 0.9.0-incubating). The vulnerability was disclosed on March 12, 2026, by researcher Hiroki Egawa via the oss-security mailing list. It carries a CVSS v3.1 base score of 6.3 (Medium) (OSS-Security, Apache Mailing List).

Technical details

The root cause is improper path validation (CWE-22) in Apache Livy's file access logic. Specifically, when the configuration value livy.file.local-dir-whitelist is set to a non-default value, the directory boundary check can be bypassed using path traversal sequences (e.g., ../). A public PoC demonstrates that a crafted JSON payload containing a URI such as file:///opt/safe-data/../sensitive/secret.txt can be submitted by an authenticated low-privileged user over the network to access files outside the whitelisted directory. The vulnerability is only exploitable when livy.file.local-dir-whitelist has been explicitly configured to a non-default value — default installations are not affected (OSS-Security, PoC GitHub).

Impact

Successful exploitation allows an authenticated attacker with low privileges to read, modify, or delete sensitive files on the Livy server host that reside outside the intended whitelisted directories. Since Apache Livy typically operates within big data environments (e.g., Apache Spark clusters), unauthorized file access could expose cluster configuration files, credentials, or sensitive data processed by Spark jobs. The confidentiality, integrity, and availability impacts are each rated low, but in sensitive data pipeline environments the practical risk may be higher due to the nature of data handled (OSS-Security, Feedly).

Exploitation steps

  1. Reconnaissance: Identify Apache Livy server instances (versions 0.3.0–0.8.x) exposed on the network, typically running on port 8998. Confirm that livy.file.local-dir-whitelist is configured to a non-default directory path.
  2. Authentication: Obtain valid low-privilege credentials for the Apache Livy REST API (authentication method depends on deployment configuration).
  3. Craft malicious payload: Construct a JSON request body targeting the Livy file submission or session API endpoint, embedding a path traversal sequence in the file URI, e.g., {"file": "file:///opt/safe-data/../sensitive/secret.txt"}.
  4. Submit request: Send the crafted HTTP POST request to the Livy REST API endpoint (e.g., /batches or /sessions) with the malicious file path.
  5. Access restricted files: The server fails to properly canonicalize the path against the whitelist, allowing the traversal to resolve to a file outside the permitted directory, which is then read or processed by the Livy server (PoC GitHub, OSS-Security).

Indicators of compromise

  • Network: Unusual authenticated HTTP POST requests to Apache Livy REST API endpoints (e.g., /batches, /sessions) containing file URIs with ../ sequences or encoded path traversal characters.
  • Logs: Apache Livy access logs showing requests with file paths containing .. segments or references to directories outside the configured livy.file.local-dir-whitelist value; unexpected file access errors in Livy server logs.
  • File System: Evidence of access to sensitive files (e.g., configuration files, credential stores) located outside the whitelisted directory, particularly if Livy process timestamps on those files are unexpectedly updated.
  • Process: Livy server process accessing files in directories not consistent with normal operational paths (PoC GitHub).

Mitigation and workarounds

The primary remediation is to upgrade Apache Livy to version 0.9.0-incubating or later, which contains the fix for this vulnerability (OSS-Security, Apache Mailing List). As an interim workaround, avoid setting livy.file.local-dir-whitelist to any non-default value, as the vulnerability is only exploitable when this configuration is explicitly modified. Additionally, restrict network access to the Livy REST API to only authorized and trusted users, and enforce strong authentication controls to limit the attack surface.

Community reactions

The vulnerability was announced on the oss-security mailing list and the Apache announcements list, with coverage appearing on security news sites such as SecurityOnline.info, which noted that Apache Livy patched both path traversal and file access flaws affecting Spark clusters (SecurityOnline). Brief social media mentions appeared on Bluesky shortly after disclosure. No major vendor statements beyond the Apache advisory or notable researcher commentary beyond the finder credit (Hiroki Egawa) have been observed.

Additional resources


SourceThis report was generated using AI

Related Java vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

GHSA-p279-2cqp-84jgCRITICAL9.6
  • Java logoJava
  • org.openidentityplatform.opendj:opendj-server-legacy
NoYesJul 24, 2026
GHSA-fp43-vj7g-pg92HIGH7.5
  • Java logoJava
  • org.omnifaces:omnifaces
NoYesJul 24, 2026
GHSA-7ppr-r889-mcf2HIGH7.5
  • Java logoJava
  • org.http4s:http4s-blaze-server_2.12
NoYesJul 24, 2026
GHSA-mhvj-jhpq-885vHIGH7.4
  • Java logoJava
  • org.http4s:http4s-blaze-server_2.13
NoYesJul 24, 2026
GHSA-46q4-43ph-c6frHIGH7.4
  • Java logoJava
  • org.http4s:blaze-http_2.12
NoYesJul 24, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management