CVE-2026-28460: OpenClaw's system.run allowlist bypass via shell line-continuation command substitution
OpenClaw up to 2026.2.21-2 can be tricked in system.run allowlist mode by splitting a command substitution across a line continuation inside double quotes. The analyzer sees an allowlisted command such as /bin/echo, but the shell runs extra non-allowlisted subcommands. Upgrade the npm package openclaw to 2026.2.22.
Published Mar 3, 2026 · Updated Mar 19, 2026 · Analysis Oct 31, 2026
What an attacker can do
In allowlist mode, OpenClaw analyses the shell wrapper's command text to decide whether every command is on the allowlist. The bypass writes $, a backslash and a newline, then ( inside double quotes. The analyzer does not see a command substitution there, so the payload looks like an allowlisted command such as /bin/echo. When the shell runs it, it folds the line continuation into $(...) and executes whatever is inside.
This only matters for deployments that set tools.exec.security=allowlist together with tools.exec.ask=on-miss or off. In those setups the allowlist is the approval boundary. The attacker needs the agent to emit the crafted command, for example through a prompt injection in a document, web page or message the agent reads. Then the injected subcommand runs with the OpenClaw user's permissions and with no approval prompt.
No CVSS vector is published for this entry. The advisory rates it medium.
Who is affected
npm package openclaw, versions up to and including 2026.2.21-2, when tools.exec.security=allowlist is configured with ask=on-miss or ask=off. Setups that always ask or deny exec are not exposed through this route. Check:
npm ls openclawopenclaw
- Ecosystem
- npm
- Affected
- < 2026.2.22
- Fixed in
- 2026.2.22
- Check
npm ls openclaw
How to fix it
Upgrade to openclaw 2026.2.22 or newer (fix commit 3f0b9dbb36c86e308267924c0d3d4a4e1fc4d1e9).
npm install [email protected]Temporary mitigation from the advisory: set tools.exec.ask=always or tools.exec.security=deny.
How to tell if you were hit
Search agent command history for commands containing a backslash followed by a newline right after $ inside double quotes, and for child processes you did not expect to start from an echo-like allowlisted command. Review your exec config for allowlist mode with ask set to on-miss or off. Beam records agent shell commands and its rules flag risky ones, so use it to review what ran.
Original advisory
From the GitHub Advisory Database (CC BY 4.0).
Summary
In OpenClaw system.run allowlist mode, shell-wrapper analysis could be bypassed by splitting command substitution as $\\ + newline + ( inside double quotes. Analysis treated the payload as allowlisted (for example /bin/echo), while shell runtime folded the line continuation into $(...) and executed non-allowlisted subcommands.
Affected Packages / Versions
- Package: npm
openclaw - Latest published affected version:
2026.2.21-2 - Affected range:
<=2026.2.21-2 - Patched version (planned next release):
2026.2.22
Impact
In deployments that opt into tools.exec.security=allowlist (with ask=on-miss or off), this can bypass approval boundaries and lead to unintended command execution.
Fix Commit(s)
3f0b9dbb36c86e308267924c0d3d4a4e1fc4d1e9
Remediation
- Upgrade to
2026.2.22(or newer) when published. - Temporary mitigation: set
tools.exec.ask=alwaysortools.exec.security=deny.
Release Process Note
patched_versions is pre-set to planned next release 2026.2.22. After npm release is out, this advisory should be ready for direct publish without additional metadata edits.
OpenClaw thanks @tdjackey for reporting.
Credited to tdjackey.
Questions
- Is CVE-2026-28460 exploitable with the default exec settings?
The advisory limits it to deployments that opt into tools.exec.security=allowlist with ask=on-miss or off. Other settings are not described as affected.
- What is the quick mitigation?
Set tools.exec.ask=always or tools.exec.security=deny until you can upgrade to 2026.2.22.
- Why does the allowlist fail here?
The analyzer and the shell read the string differently. The analyzer does not treat the split
$backslash-newline(as command substitution, but the shell joins the lines and runs it.
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
