Junglewise Threat Intelligence

CVE-2026-75858: CodeWhale rlm_eval approval bypass code execution

CVE-2026-75858 · Severity: high · CVSS 7.8 · Published 2026-09-04

Executive brief

CodeWhale is an AI agent framework that includes a tool called rlm_eval to execute Python code. The tool is configured to bypass user approval policies, automatically executing any Python code the AI model requests without prompting the user for permission. An attacker can inject malicious code through untrusted content (web pages, fetched files, or other sources) that the agent reads, causing the tool to execute arbitrary code on the user's computer with full access to their files, credentials, and system resources.

Technical details

The vulnerability is a code injection flaw in the rlm_eval and rlm_open tools in CodeWhale. The rlm_eval tool's approval_requirement() method returns ApprovalRequirement::Auto, which overrides the trait default of Required for tools with ExecutesCode capability. This causes the engine's approval gate to short-circuit: when approval_requirement() is Auto, the condition (spec.approval_requirement() != ApprovalRequirement::Auto && !registry.context().auto_approve) evaluates to false, preventing any Event::ApprovalRequired from being emitted. As a result, the user's --approval-policy (on-request, unless-trusted, never) is never consulted. The rlm_eval tool reads the LLM-controlled "code" field and passes it directly to kernel.run() in a real python3 interpreter. The companion rlm_open tool can stage content, file reads, or URL fetches into the Python kernel before rlm_eval executes. Both tools are registered unconditionally with no disable flag. An attacker can inject prompt injection payloads via any untrusted content the agent processes (web pages, fetched URLs, repo files, MCP tool results) to trigger unsandboxed code execution at the user's UID, allowing theft of SSH keys, cloud credentials, and other secrets, or achieving persistence via shell rc files and authorized_keys. The fix in version 0.8.64 (commit 57f3c89) addresses this by respecting the approval policy for these tools.

Affected products

  • CodeWhale codewhale-tui >= 0.8.41, < 0.8.64
  • CodeWhale codewhale >= 0.8.41, < 0.8.64
  • DeepSeek deepseek-tui >= 0.8.33, <= 0.8.41
  • DeepSeek deepseek-tui >= 0.8.33, < 0.8.41

Timeline

  • 2026-09-04: disclosed: Public disclosure via GitHub Advisory Database
  • 2026-07-16: patched: Fix available in version 0.8.64 (commit 57f3c89471e27ac4032d9791f6885e5d4408c381)

References

Related threats