# CVE-2026-42074: OpenClaude: Sandbox Bypass via Model-Controlled `dangerouslyDisableSandbox` Input

> A prompt-injected LLM can bypass the sandbox by setting a dangerous parameter, leading to arbitrary host-level code execution.

- **Severity:** Critical 9.3 (`CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 2 Jun 2026
- **Updated:** 2 Jun 2026
- **Also known as:** GHSA-m77w-p5jj-xmhg

## What is CVE-2026-42074?

CVE-2026-42074 is a critical vulnerability in Gitlawb openclaude, published on 2 Jun 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

OpenClaude is an open-source coding-agent command line interface for cloud and local model providers. Prior to version 0.5.1, the dangerouslyDisableSandbox parameter is exposed as part of the BashTool input schema, meaning the LLM (an untrusted principal per the project's own threat model) can set it to true in any tool_use response. Combined with the default allowUnsandboxedCommands: true setting, a prompt-injected model can escape the sandbox for any arbitrary command, achieving full host-level code execution. This issue has been patched in version 0.5.1.

Weakness: CWE-306 (Missing Authentication for Critical Functionality), CWE-284 (Improper Access Control)

## Which versions are affected by CVE-2026-42074?

2 open source packages ship an affected version, including openclaude. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `openclaude` | npm | All versions | 0.5.1 |
| `openclaude` | npm | All versions | 0.5.1 |

Products: Gitlawb Openclaude.

## How do I fix CVE-2026-42074?

Upgrade openclaude to 0.5.1 or later.

## Is CVE-2026-42074 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-42074 exists.

## Other vulnerabilities in Gitlawb openclaude

- [CVE-2026-35570](https://insights.sbomify.com/CVE-2026-35570/): OpenClaude has Sandbox Bypass via Early-Exit Logic Flaw that Allows Path Traversal (high 8.4)
- [CVE-2026-42073](https://insights.sbomify.com/CVE-2026-42073/): OpenClaude's MCP OAuth Callback: State Check Bypass via error Param Leads to DoS (medium 6.5)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2026-42074 and fix it if it is affected.

What it is: CVE-2026-42074 is a critical vulnerability in Gitlawb openclaude, published on 2 Jun 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-42074 exists.

Affected packages and fixed versions:
- openclaude (npm): affected all versions; fixed in 0.5.1
- openclaude (npm): affected all versions; fixed in 0.5.1

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2026-42074/ (Markdown: https://insights.sbomify.com/CVE-2026-42074/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2026-42074
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2026-42074
- OSV: https://osv.dev/vulnerability/CVE-2026-42074

---
From sbomify Insights: https://insights.sbomify.com/CVE-2026-42074/
Summaries are generated and may contain mistakes; the official description above is the record.
