CVE-2024-5986

h2oai/h2o-3 · h2oai/h2o-3

A critical vulnerability has been identified in the h2oai/h2o-3 data analysis platform, which allows a remote, unauthenticated attacker to write arbitrary files to the server.

Executive summary

A critical vulnerability has been identified in the h2oai/h2o-3 data analysis platform, which allows a remote, unauthenticated attacker to write arbitrary files to the server. Successful exploitation could lead to remote code execution, granting the attacker complete control over the affected system, the ability to steal sensitive data, and pivot to other systems within the network.

Vulnerability

This vulnerability is an arbitrary file write flaw that can be exploited through a two-step process. First, an attacker sends a specially crafted request to the /3/Parse API endpoint to create an in-memory data frame from an empty file, injecting malicious content into the frame's header. Second, the attacker uses the /3/Frames/framename/export endpoint to save this malicious frame to a file on the server's filesystem, specifying an arbitrary path and filename. This allows the attacker to overwrite critical system files, such as SSH authorized keys (~/.ssh/authorized_keys), web application scripts, or system cron jobs, leading to remote code execution.

Business impact

This vulnerability is rated as critical severity with a CVSS score of 9.1. Exploitation could lead to a complete compromise of the server hosting the h2o-3 software. The potential business impact is severe, including theft of sensitive corporate or customer data processed by the platform, reputational damage, and significant operational disruption. An attacker with full system access could also use the compromised server as a foothold to launch further attacks against the internal network, escalating the scope of the breach.

Remediation

Immediate Action: Immediately apply the security patch provided by the vendor. The primary remediation is to update the h2oai/h2o-3 software to the latest version that addresses this vulnerability. After patching, review system logs for any signs of compromise prior to the update.

Proactive Monitoring: Security teams should actively monitor web server and application logs for suspicious POST requests to the /3/Parse and /3/Frames/{frame_name}/export endpoints. Monitor for unexpected file modifications or creations in sensitive directories, particularly application directories, user home directories (e.g., .ssh/), and system script locations (e.g., /etc/cron.d/).

Compensating Controls: If immediate patching is not feasible, implement the following controls to reduce risk:

  • Use a firewall or reverse proxy to restrict network access to the h2o-3 instance, allowing connections only from trusted IP addresses.
  • Run the h2o-3 service with a dedicated, low-privilege user account to limit the impact of a file-write, preventing the overwrite of critical system-level files.
  • Deploy a Web Application Firewall (WAF) with rules to block or alert on requests containing suspicious path traversal sequences or filenames targeting the vulnerable API endpoints.

Exploitation status

Public Exploit Available: false

Analyst recommendation

Given the critical 9.1 CVSS score and the potential for complete system compromise, immediate remediation is strongly recommended. Organizations must prioritize patching all vulnerable h2o-3 instances without delay. The risk of remote code execution represents a direct and severe threat to the confidentiality, integrity, and availability of the affected system and the data it processes. Even in the absence of known exploits, the severity of this vulnerability warrants urgent attention.