NewApp Monitoring is liveSign up free
AgentbeamBeta
AI agent vulnerability · OpenClaw

CVE-2026-44995: OpenClaw: MCP stdio server env could load dangerous startup variables from workspace config

mediumCVSS 4.0 5.4GHSA-mj59-h3q9-ghfh

OpenClaw before 2026.4.20 lets a workspace's MCP stdio configuration pass startup variables such as `NODE_OPTIONS`, `LD_PRELOAD` or `BASH_ENV` to the MCP server it spawns. A malicious workspace can make that child process load attacker code when you start a session that uses the server. Upgrade to openclaw 2026.4.20.

Published Apr 25, 2026 · Updated May 19, 2026 · Analysis Oct 29, 2026

What an attacker can do

OpenClaw can launch local MCP servers over stdio, using an env block from the workspace's MCP configuration. Before the fix, that block was passed to the child process as written. Several environment variables change what a process loads when it starts. NODE_OPTIONS can preload a Node.js module, LD_PRELOAD can inject a shared library and BASH_ENV makes Bash run a script. A repository that ships an MCP config setting one of these runs its own code the moment the MCP server starts.

The attacker needs the operator to open OpenClaw in the malicious workspace and start a session that uses that MCP server. The code then runs as the operator, with access to their files, tokens and SSH keys. The CVSS 4.0 vector shows local access, low privileges and user action, with high confidentiality, integrity and availability impact on the host. The advisory notes the limit: the issue stays inside the local or workspace trust boundary, so it rates medium, not high.

Developers who clone unfamiliar projects and let an agent start their MCP servers are the typical victims. The same applies to CI jobs that run OpenClaw in a checked-out pull request.

Who is affected

The openclaw npm package before 2026.4.20. You are exposed when you run OpenClaw in a workspace whose MCP configuration defines stdio servers with an env section you did not write.

npm ls openclaw

Also review workspace MCP config files for NODE_OPTIONS, LD_PRELOAD, BASH_ENV or similar entries.

openclaw

Ecosystem
npm
Affected
< 2026.4.20
Fixed in
2026.4.20
Check
npm ls openclaw

How to fix it

Upgrade to openclaw 2026.4.20:

npm install [email protected]

The fix commits are 62fa5071896e95edc7f67d1cebc70a2859e283af and 85d86ebc4bf3d2226d39d132a484f4f7a299fa1b. OpenClaw now filters MCP stdio environment entries through the host environment safety denylist before it spawns stdio MCP servers. The advisory lists no workaround. Until you upgrade, read a workspace's MCP configuration before starting a session in it.

How to tell if you were hit

Search workspace MCP configuration files for stdio servers whose env block sets NODE_OPTIONS, LD_PRELOAD or BASH_ENV. On a host that may have been hit, review child processes of OpenClaw for MCP servers started with unexpected preload modules or libraries, and for unfamiliar scripts or network connections spawned alongside them. The advisory names no log signature.

Original advisory

From the GitHub Advisory Database (CC BY 4.0).

Affected Packages / Versions

  • Package: openclaw (npm)
  • Affected versions: < 2026.4.20
  • Patched version: 2026.4.20

Impact

Workspace MCP stdio configuration could pass dangerous process-startup environment variables such as NODE_OPTIONS, LD_PRELOAD, or BASH_ENV to the spawned MCP server process. In a malicious workspace, this could make the MCP child load attacker-controlled code when the operator starts a session that uses that MCP server.

The impact is limited to local/workspace trust boundaries and requires the operator to run OpenClaw in a workspace containing the malicious MCP configuration. Severity is therefore medium, not high/critical.

Fix

OpenClaw now filters MCP stdio environment entries through the host environment safety denylist before spawning stdio MCP servers.

Fix commits:

  • 62fa5071896e95edc7f67d1cebc70a2859e283af
  • 85d86ebc4bf3d2226d39d132a484f4f7a299fa1b

Release

Fixed in OpenClaw 2026.4.20.

Credited to garagon.

Questions

Does CVE-2026-44995 need the attacker on my machine?

No, but it needs you to open OpenClaw in the attacker's workspace and start a session that uses its MCP server. The advisory describes a local or workspace trust boundary.

Which variables are the problem?

The advisory names NODE_OPTIONS, LD_PRELOAD and BASH_ENV, which make a starting process load attacker-controlled code.

Why is it rated medium?

The advisory says it stays inside local and workspace trust boundaries and needs the operator to run OpenClaw in the malicious workspace.

What does the fix do?

It filters MCP stdio environment entries through the host environment safety denylist before spawning the server. Fixed in 2026.4.20.

References

How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology

More OpenClaw vulnerabilities

All OpenClaw entries