CVE-2026-41396
7.8OpenClaw · OpenClaw
OpenClaw allows workspace .env files to override the plugin directory environment variable, enabling the injection of malicious plugins through compromised workspace configurations.
Executive summary
A critical vulnerability in OpenClaw allows attackers to execute arbitrary code by manipulating environment variables to inject malicious plugins into the workspace.
Vulnerability
This vulnerability, categorized as CWE-829, occurs because the application fails to properly sanitize the OPENCLAW_BUNDLED_PLUGINS_DIR environment variable when defined in a local workspace .env file. An attacker who can influence the workspace configuration can force the application to load plugins from an untrusted directory, bypassing trust verification mechanisms.
Business impact
The ability to inject malicious plugins grants an attacker the power to execute arbitrary code within the context of the OpenClaw environment. With a CVSS score of 7.8, this flaw represents a significant risk to data integrity and system confidentiality, as compromised plugins can access sensitive workspace data or facilitate lateral movement within the development environment.
Remediation
Immediate Action: Update OpenClaw to version 2026.3.31 or later to implement the fix for environment variable overrides.
Proactive Monitoring: Review application logs for unexpected plugin loading paths or unauthorized modifications to local workspace configuration files.
Compensating Controls: Restrict write access to workspace directories and .env files to prevent unauthorized users from modifying environmental configurations.
Exploitation status
Public Exploit Available: No (exploit_available: false)
Analyst recommendation
Given the potential for complete system compromise via arbitrary code execution, this vulnerability poses a severe threat to development environments. Organizations should prioritize the immediate update of OpenClaw to the patched version, 2026.3.31, to ensure that plugin trust verification cannot be bypassed via local environment configurations.
More OpenClaw CVEs
Sources
Originally found and disclosed by Nathan (@nexrin), KeenSecurityLab, qclawer, per the CVE Program record.
- GitHub Security Advisory (GHSA-qcj9-wwgw-6gm8) Vendor advisory
- Patch Commit Patch commit
- VulnCheck Advisory: OpenClaw < 2026.3.31 - Environment Variable Override of Plugin Trust Root Third-party advisory