GHSA-mj4p-rc52-m843: OpenClaw: Sandbox staged writes could escape the verified parent directory before commit
OpenClaw's sandbox fs-bridge checked a write's destination but did not pin the temporary staging file to the verified parent directory. An attacker who swaps a parent-path alias during a race can make the temp file land outside the writable mount. The npm package `openclaw` is fixed in 2026.3.11.
Published Mar 13, 2026 · Analysis Oct 31, 2026
What an attacker can do
When a sandboxed agent writes a file, the fs-bridge stages the content in a temporary file and then atomically replaces the target. The old staging flow created and wrote that temporary file with shell path operations in the target directory. The final replace revalidated the destination, but that guard covered only the rename, not the earlier temp-file creation.
This is a time-of-check to time-of-use race combined with link following (CWE-367 and CWE-59). If an attacker changes a parent-path alias, such as a symlink, between the check and the staging step, the temp file is created and filled outside the intended writable mount.
The result is that attacker-controlled bytes are written outside the validated path before the final guard runs. The advisory rates integrity and availability impact high and says damage is limited to the writable mount scope. Attack complexity is high because the attacker must win a race, and the vector is local with low privileges. In practice this matters for teams that run untrusted or prompt-injected agents in the sandbox and rely on it to confine file writes.
Who is affected
The advisory lists openclaw up to and including 2026.3.8, and the packages data lists versions below 2026.3.11. The flaw sits in the sandbox filesystem bridge, so deployments that use OpenClaw's sandbox with writable mounts are the ones exposed. Check the version:
npm ls openclawopenclaw
- Ecosystem
- npm
- Affected
- < 2026.3.11
- Fixed in
- 2026.3.11
- Check
npm ls openclaw
How to fix it
Upgrade to 2026.3.11 or later.
npm install -g [email protected]The fix resolves a pinned mount root and a relative parent path, creates the temporary file inside the verified parent directory, and performs the final atomic replace from that same pinned directory context. The advisory names no other workaround.
How to tell if you were hit
Look for stray temporary files outside the sandbox's writable mount, and for symlinks or aliases in parent paths that change during agent runs. Repeated rapid write attempts from one sandboxed session can indicate a race attempt. Beam records agent shell commands and file access, which can show an agent creating links or writing near mount boundaries.
Original advisory
From the GitHub Advisory Database (CC BY 4.0).
Summary
In affected versions of openclaw, sandbox fs-bridge writes validated the destination before commit, but temporary file creation and population were not pinned to a verified parent directory. A raced parent-path alias change could cause the staged temp file to be created outside the intended writable mount before the final guarded replace step.
Impact
This is a sandbox boundary bypass affecting integrity and availability within the writable mount scope. Attacker-controlled bytes could be written outside the intended validated path before the final guarded step ran.
Affected Packages and Versions
- Package:
openclaw(npm) - Affected versions:
<= 2026.3.8 - Fixed in:
2026.3.11
Technical Details
The older staging flow created and wrote the temporary file using target-directory shell path operations before the final replace step revalidated the destination. That meant the last guard protected only the final rename, not the earlier temp-file materialization path.
Fix
OpenClaw now resolves a pinned mount root plus relative parent path, creates the temporary file inside the verified parent directory, and performs the final atomic replace from that pinned directory context. The fix shipped in [email protected].
Workarounds
Upgrade to 2026.3.11 or later.
Credited to tdjackey.
Questions
- Is this exploitable remotely?
No. The CVSS vector is local with high attack complexity and low privileges. The attacker needs to run in the sandbox and win a race against the path check.
- What is the vulnerable behaviour?
The sandbox fs-bridge created its temporary staging file with shell path operations in the target directory, so the check on the final destination did not cover where the temp file was created.
- Which version fixes it?
openclaw 2026.3.11, which creates the temp file inside a verified parent directory and replaces from the same pinned context.
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 entriesCVE-2026-62197
OpenClaw: Browser CDP discovery could accept blocked WebSocket URLs
medium8.5Oct 21, 2026CVE-2026-35630
OpenClaw: QQBot native approval buttons did not enforce configured approver identity
high8.0Jul 2, 2026CVE-2026-53806
OpenClaw: Combined POSIX shell options could confuse exec revalidation
high8.8Jul 2, 2026CVE-2026-53809
OpenClaw: Embedded runner policy could be confused by provider aliases
medium3.8Jul 2, 2026CVE-2026-53810
OpenClaw's marketplace runtime extension metadata could point at unscanned payloads
high8.8Jul 2, 2026CVE-2026-53811
OpenClaw: Matrix allowFrom could bind to mutable display names
high8.8Jul 2, 2026
