CVE-2026-53858: Local Code Execution via Untrusted Search Path in OpenClaw
Vulnerability ID: CVE-2026-53858
CVSS Score: 7.1
Published: 2026-06-18
OpenClaw versions prior to 2026.5.2 are vulnerable to an untrusted search path flaw (CWE-426) during workspace initialization. When an operator opens a workspace, the application parses the workspace's local .env file and uses the unvalidated STATE_DIRECTORY variable to resolve and execute bundled runtime dependencies. An attacker can exploit this to achieve local code execution under the security context of the operator.
TL;DR
OpenClaw prior to 2026.5.2 loads critical system state paths from untrusted workspace .env files, enabling local code execution through dependency path hijacking.
Technical Details
- CWE ID: CWE-426 (Untrusted Search Path)
- Attack Vector: Local (L)
- CVSS v3.1 Score: 7.1 (High)
- EPSS Score: 0.00124 (Percentile: 2.46%)
- Impact: Local Code Execution (LCE)
- Exploit Status: None (No public exploit/PoC available)
- KEV Status: Not Listed
Affected Systems
- OpenClaw (npm package 'openclaw') running on developer or operator workspaces
-
openclaw: < 2026.5.2 (Fixed in:
2026.5.2)
Mitigation Strategies
- Upgrade OpenClaw to version 2026.5.2 or higher
- Manually inspect and sanitize workspace .env files before opening
- Disable auto-loading of repository-level environment configurations
Remediation Steps:
- Identify all active installations of the openclaw npm package across development environments.
- Update openclaw dependencies to version 2026.5.2 via 'npm update openclaw'.
- Configure static analysis rules to flag any local repository containing 'STATE_DIRECTORY' overrides inside '.env' files.
- Restrict outbound network access from OpenClaw execution boundaries to prevent payload exfiltration.
References
- GitHub Security Advisory GHSA-wc84-j36w-pw4x
- VulnCheck Security Advisory
- CVE.org Official Record
- NVD Official Record
Read the full report for CVE-2026-53858 on our website for more details including interactive diagrams and full exploit analysis.
Top comments (0)