Skip to content

AAK-MCP-CODEWHALE-CVE-2026-75858-001: CodeWhale auto-approved code execution: rlm_eval and exec_shell_interact bypass the approval policy (codewhale from 0.8.41 below 0.8.64)

Severity
HIGH
Category
Supply Chain (supply-chain)
Scanner
agent_audit_kit/scanners/mcp_cve_pins_2026_07.py
Auto-fixable
No.
SARIF name
CodeWhaleAutoApprovedExecution

What it detects

CodeWhale between 0.8.41 and 0.8.64 ships two tools whose approval_requirement() returns ApprovalRequirement::Auto, which the engine treats as "never prompt". That silently overrides the user's configured --approval-policy for the two tool classes it should never be overridden for. rlm_eval runs model-supplied Python in a python3 interpreter with no prompt and no audit step (CVE-2026-75858, CVSS 7.8, CWE-94); exec_shell_interact (alias exec_interact) writes LLM-controlled stdin into an already-approved long-running interactive session — a python3 -i REPL, mysql, ssh, or sudo -i — so commands run at that process's privilege level (CVE-2026-75857, CVSS 7.0). Neither needs a malicious operator: prompt injection in any untrusted content the agent reads (a fetched page, a repository file, an MCP tool result) reaches both, and the companion rlm_open tool can stage exactly that content. Both are fixed in 0.8.64. deepseek-tui is the same project before it was renamed and is carried by both advisories; it is deprecated on npm in favour of codewhale, so it has no fixed release of its own.

How to fix

Upgrade codewhale to >= 0.8.64 and pin it. If the manifest still names deepseek-tui, that package is deprecated and its line ends before the fix: migrate to codewhale >= 0.8.64 rather than upgrading in place. Until then, treat any approval policy you have configured as not in force for rlm_eval or exec_shell_interact and remove those tools from the exposed tool set, since a policy the engine never consults offers no protection.

To confirm the finding is gone, report only this rule:

agent-audit-kit scan . --rules AAK-MCP-CODEWHALE-CVE-2026-75858-001

Limitations

Reads codewhale and deepseek-tui, each against its own fix floor, in requirements*.txt at any depth and, at the project root only, in pyproject.toml, Pipfile, package.json, .mcp.json, mcp.json, claude_desktop_config.json and the Pipfile.lock, poetry.lock, uv.lock, package-lock.json, pnpm-lock.yaml and yarn.lock lockfiles, taking the lowest version a range allows and reporting a reference that states no version. The dependency is not read when it is declared in a sub-directory manifest (packages/app/package.json) or in a lockfile format the reader does not parse (a Yarn 2+ yarn.lock). Cargo manifests are not read, so the crates.io crate codewhale-tui, which has the same defect, is not reported. A file over 2 MB, or a lockfile over 32 MiB, is not read. A declaration nested more than 64 levels deep in package.json, a TOML manifest or an MCP config (an MCP server more than 62) is still judged, and reported without a line; a lockfile entry keeps its line at any depth.

References


All rules. This page is generated from the rule registry when the documentation is built; to change it, change the rule in agent_audit_kit/rules/builtin.py. To give the rule a hand-written write-up, add docs/rules/AAK-MCP-CODEWHALE-CVE-2026-75858-001.md: the page then shows that text, with the registry reference appended under it.