Executive brief
OpenClaw, a tool used for managing and executing commands on remote hosts, contains a flaw where the approval interface may truncate long commands. This allows a malicious user to submit a command that appears harmless in the preview but contains hidden, dangerous instructions at the end. If an administrator approves the truncated command, the full malicious command will execute, potentially leading to unauthorized system access or data loss.
Technical details
A vulnerability in OpenClaw's execution approval workflow allows for command display truncation. When an authenticated user submits a host execution request with an exceptionally long command string, the administrative approval UI may only display the initial portion of the command. Because the backend retains and executes the full original string upon approval, an attacker can append malicious shell operations (suffixes) that are invisible to the reviewer. This is classified as an improper authorization and access control issue (CWE-284, CWE-863). Exploitation requires the attacker to have permissions to request executions and relies on an administrator (user interaction) approving the truncated request. The issue is resolved in version 2026.5.18.
Affected products
- OpenClaw openclaw < 2026.5.18
Timeline
- 2026-05-28: disclosed
- 2026-07-02: advisory
- 2026-05-18: patched: First stable patched version released.