HIGH 7.1

CVE-2026-53846: OpenClaw Path Traversal in npm_execpath Configuration

OpenClaw before version 2026.4.29 contains a vulnerability that allows attackers to hijack the package manager used during dependency installation. An attacker with access to a workspace can craft a malicious .env file that tricks the install process into running an unauthorized package manager executable. This could enable them to inject malicious code into the build environment and compromise software artifacts.

Source data · NVD / CISA · public domain

CVSS
3.1 · 7.1 HIGH · CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:N
Weaknesses (CWE)
CWE-426
Affected products
5 configuration(s)
Published / Modified
2026-06-16 / 2026-06-18

NVD description (verbatim)

OpenClaw before 2026.4.29 contains a path traversal vulnerability in the install helper that allows workspace .env files to override the npm_execpath configuration used for bundled runtime dependency installation. Attackers with workspace access can execute unintended local package-manager executables during dependency setup to compromise the build environment.

2 reference(s) · View on NVD →

SEC.co analysis · AI-assisted, reviewed against source

Technical summary

CVE-2026-53846 is a path traversal vulnerability (CWE-426) in OpenClaw's install helper that fails to properly validate workspace .env file configuration. The flaw allows untrusted .env files to override the npm_execpath parameter, which controls which package manager executable is invoked during bundled runtime dependency installation. An unauthenticated local attacker can exploit this to substitute their own malicious package manager and gain arbitrary code execution in the build environment context. The vulnerability requires user interaction (installation trigger) but no privilege escalation.

Business impact

Build environments are a high-value attack target. Successful exploitation allows attackers to poison dependencies before they reach production, potentially affecting every downstream user of the compromised software. This creates supply chain risk at the point of package generation. Organizations using OpenClaw in CI/CD pipelines or shared development workspaces face heightened risk of silent compromise, where malicious code is injected into released packages without detection.

Affected systems

OpenClaw versions prior to 2026.4.29 are affected. Specific version ranges and affected distributions should be verified against the vendor advisory. The vulnerability impacts any installation using the affected install helper with workspace-based dependency management.

Exploitability

Exploitation is straightforward but requires local workspace access. An attacker must place a crafted .env file in the workspace, then trigger an installation event (e.g., by committing code or manually running dependency setup). The CVSS score of 7.1 reflects this: local attack vector with no privilege requirements but requiring user interaction to complete the installation process. This makes it practical for insider threats or compromised development accounts.

Remediation

Update OpenClaw to version 2026.4.29 or later. The fix implements proper validation of .env file configuration and prevents workspace files from overriding critical npm_execpath settings. Organizations should prioritize patching development and CI/CD environments where dependency installation occurs.

Patch guidance

Apply the 2026.4.29 release or later. Before patching, audit recent builds generated with affected versions to identify potential supply chain contamination. Verify patch completeness by confirming that .env files no longer override npm_execpath in your installation logs. Consider running builds in isolated containers to limit blast radius during the patching window.

Detection guidance

Monitor for suspicious .env files in workspaces containing npm_execpath overrides that point to non-standard executables. Check installation logs for unexpected package manager invocations. Implement code review policies that flag changes to .env files in build-critical directories. Compare actual package manager binaries executed during builds against expected paths. In CI/CD pipelines, enforce environment variable immutability to reject workspace overrides.

Why prioritize this

This vulnerability sits at the intersection of low exploitation friction and high business impact. Build environment compromise is difficult to detect but compromises all downstream artifacts. The presence in development workflows alongside the ability to execute arbitrary code during installation makes this a tier-one concern for security teams managing shared development infrastructure or publishing packages.

Risk score, explained

The CVSS 7.1 (HIGH) rating reflects the high integrity and confidentiality impact combined with local attack vector and low complexity. The lack of privileges required and presence of user interaction (triggering installation) are balanced against the fact that this affects only local code execution rather than system-wide impact. For supply chain contexts, the business risk significantly exceeds the numeric score.

Frequently asked questions

Can this vulnerability be exploited remotely?

No. The vulnerability requires local workspace access to place the malicious .env file. It cannot be triggered over a network. However, if an attacker gains remote code execution on a build server or development machine, they can exploit this locally.

What happens if I update my version but don't audit past builds?

Patching protects future builds from this specific attack. However, any packages built with affected versions may already contain injected code. You should audit build logs for suspicious package manager invocations and consider re-releasing affected packages with the patched version once you confirm the fix is deployed.

Does this affect end users of packages built with vulnerable OpenClaw?

Yes. If the vulnerability was exploited during a package build, the malicious code is embedded in the released package and will execute on end-user systems. This is why build environment security is a supply chain priority.

How do I verify that a build was compromised?

Check installation logs for unexpected package manager paths in npm_execpath during dependency setup. Review .env files committed around build times for suspicious overrides. Compare package contents against source to identify unauthorized modifications. Consider re-building with the patched version and comparing artifacts.

This analysis is based on publicly available vulnerability data current as of the publication date. Organizations should verify patch version numbers and affected product ranges against the official vendor advisory before deployment. Supply chain compromise risks extend beyond this single CVE; implement layered controls including artifact signing, dependency pinning, and build environment isolation. No active exploits are known at time of publication, but testing should be conducted in isolated environments only. Source: NVD (public-domain), retrieved 2026-07-24. Analysis generated by SEC.co (claude-haiku-4-5).