CodeWhaleに任意のプログラムを実行される脆弱性、0.9.0で修正
Summary
CodeWhaleには、攻撃者が仕込んだ内容によって承認なしに開発者のホストで任意のプログラムを実行される脆弱性があります。fd、rg、git grepの一部オプションが読み取り専用として扱われ、確認の表示なしに外部プログラムが実行されるおそれがあります。影響を受けるのは0.9.0より前の版で、0.9.0で修正されています。
AI summary
Produced by SecPulse using an external AI model; it may contain mistakes. Check the original description and references below before acting on it.
CodeWhaleには、攻撃者が仕込んだ内容によって承認なしに開発者のホストで任意のプログラムを実行される脆弱性があります。fd、rg、git grepの一部オプションが読み取り専用として扱われ、確認の表示なしに外部プログラムが実行されるおそれがあります。影響を受けるのは0.9.0より前の版で、0.9.0で修正されています。
Affected packages
| Package | Affected → Fixed | |
|---|---|---|
| HmbownCodeWhale | — | Not listed |
| codewhale-hqCodeWhale | — | Not listed |
| crates.iocodewhale-tui |
< 0.9.0→ 0.9.0 |
0.9.0 |
| npmcodewhale |
< 0.9.0→ 0.9.0 |
0.9.0 |
| rustcodewhale-tui |
< 0.9.0→ 0.9.0 |
0.9.0 |
Original description The description as published by the source.
Maintainer resolution
The CodeWhale maintainers validated this report. CodeWhale 0.8.67 and earlier are affected. Version 0.9.0 contains the fix in commit 208421b9d23d81cea3311a1eeb2a2ea81d637686. Users should upgrade to 0.9.0 or later. The original reporter analysis is preserved below.
Summary
The interactive Agent profile of DeepSeek-TUI (CodeWhale) is explicitly documented to gate every shell command behind an approval prompt (config.rs:3725-3736). However, ExecShellTool::approval_requirement_for(&tool_input) downgrades the requirement from Required to Auto for any command the classifier deems "parallel read-only" (shell.rs:2314-2320). registered_tool_approval_required returns false for Auto before the auto_approve check runs (turn_loop.rs:37-38), so no prompt is shown even for a user who never enabled YOLO. The classifier is_parallel_readonly_command (command_safety.rs:389) rejects only shell metacharacters and then matches the flag-stripped base command name against an allowlist that includes fd, rg, and git grep. Those tools execute arbitrary external programs through documented flags (fd -x/--exec, rg --pre, git grep --open-files-in-pager) that need no shell metacharacters — yielding silent arbitrary-program execution in the default profile. Same silent-RCE class as CVE-2026-45311 (run_tests) but via a different, unpatched tool and code path.
Root Cause
approval_requirement_for downgrades exec_shell to Auto whe…
Source: CVE.org (CVE Program・cvelistV5) NVD GitHub Advisory
References
- advisory github.com
- package github.com
- web github.com
- web github.com
- web github.com
- web nvd.nist.gov
- web github.com