OpenClaw Arbitrary Directory Deletion Vulnerability in OpenShell Mirror Mode

Vulnerability

A vulnerability allowing arbitrary directory deletion has been identified in OpenClaw versions prior to 2026.4.2. This issue arises in the OpenShell mirror backend, where the application accepts arbitrary absolute paths for remoteWorkspaceDir and remoteAgentWorkspaceDir. In mirror mode, these paths are used for remote cleanup and overwrite operations. As a result, an attacker who can influence these configuration values could cause the deletion of unintended remote directory contents, which would then be replaced with uploaded workspace data.

Impact

Exploitation of this vulnerability could lead to unintended deletion of remote directory contents, causing data loss and disruption of normal operations.

Reproduction

To reproduce this vulnerability, set up OpenClaw in a version prior to 2026.4.2 and configure the OpenShell plugin to use arbitrary absolute paths for 'remoteWorkspaceDir' and 'remoteAgentWorkspaceDir'. When the application performs a mirror sync, it will delete contents from the specified remote directories and replace them with the uploaded workspace data, demonstrating the directory deletion vulnerability.

Remediation

Users can upgrade to OpenClaw version 2026.4.2 or later to address this vulnerability.

Added: Apr 28, 2026, 9:40 PM
Updated: Apr 28, 2026, 9:40 PM

Vulnerability Rating

Custom Algorithm
spread
0.0
impact
2.5
exploitability
7.7
remediation
0.0
relevance
6.9
threat
4.8
urgency
2.9
incentive
0.0

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.