File Read Bypass Vulnerability in OpenClaw Package
Summary
GHSA-3xfw-4pmr-4xc5: OpenClaw safeBins grep -e File Read Bypass (stdin-only policy bypass). Affects openclaw versions < 2026.2.21. Fixed in 2026.2.21. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
OpenClaw is an open-source tool designed for executing safe binaries in a controlled environment. It provides a mechanism to run commands while ensuring that only specified binaries can be executed, thus enhancing security. However, a recent vulnerability has been identified in its tools.exec.safeBins feature, specifically related to the grep command, which could allow unauthorized file access under certain conditions.
Vulnerability Detail
The vulnerability arises from a stdin-only policy bypass in the OpenClaw package, specifically when using the grep command with the -e or --regexp flag. This configuration allows an attacker to supply a pattern that is treated as a flag value, enabling the use of a positional operand that can reference a file, such as .env. This undermines the intended security model, allowing unauthorized access to sensitive files in the working directory. The technical implementation in src/infra/exec-safe-bin-policy.ts incorrectly permits this behavior, leading to potential exposure of sensitive information.
How To Fix
Latest published version: 2026.10.6 as of 22 Oct 2026
npm install openclaw@2026.10.6
Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.
If you need the minimum change
2026.2.21
This is the first release that contains the fix.
npm install openclaw@2026.2.21
Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →
Workaround
As a temporary workaround, avoid using the grep command in the tools.exec.safeBins configuration until you can update to the patched version. If you must use it, ensure that the grep command is not included in the safe binaries list to prevent potential exploitation.
Conclusion
In summary, the OpenClaw package has a vulnerability that allows file read bypass when using the grep command under certain conditions. It is crucial for users to update to the patched version to secure their applications. Additionally, using Vulert can help monitor and alert for such vulnerabilities in real-time.
See every vulnerability recorded for openclaw →
FAQ
The vulnerability is a file read bypass that allows unauthorized access to files when using the grep command with specific flags.
You can check if your application is affected by using the Vulert playground at Vulert Scanner, which analyzes your package-lock.json for vulnerabilities.
The CVSS score for this vulnerability is 5.1, indicating a moderate level of risk.
Yes, you can temporarily remove grep from the safe binaries list to mitigate the risk until you can update to the patched version.
The vulnerability was reported by a user identified as @athuljayaram.
References
Related vulnerabilities
Recent vulnerabilities recorded for openclaw.
Follow Vulert in Google
Get more Vulert vulnerability and dependency-security updates in Google Search and AI results.