<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Deepseek-Tui-Cli (&gt;= 0.3.0, &lt; 0.8.23) — CraftedSignal Threat Feed</title><link>https://feed.craftedsignal.io/products/deepseek-tui-cli--0.3.0--0.8.23/</link><description>Trending threats, MITRE ATT&amp;CK coverage, and detection metadata. Fed continuously.</description><generator>Hugo</generator><language>en</language><managingEditor>hello@craftedsignal.io</managingEditor><webMaster>hello@craftedsignal.io</webMaster><lastBuildDate>Thu, 14 May 2026 20:36:21 +0000</lastBuildDate><atom:link href="https://feed.craftedsignal.io/products/deepseek-tui-cli--0.3.0--0.8.23/feed.xml" rel="self" type="application/rss+xml"/><item><title>DeepSeek TUI run_tests Tool Enables RCE via Malicious Repository Without Approval</title><link>https://feed.craftedsignal.io/briefs/2026-05-deepseek-tui-rce/</link><pubDate>Thu, 14 May 2026 20:36:21 +0000</pubDate><author>hello@craftedsignal.io</author><guid isPermaLink="true">https://feed.craftedsignal.io/briefs/2026-05-deepseek-tui-rce/</guid><description>DeepSeek TUI's `run_tests` tool allows for remote code execution (RCE) via a malicious repository without user approval due to auto-approval of `cargo test` execution, which can be triggered by prompt injection via the `AGENTS.md` file, affecting versions &gt;= 0.3.0 and &lt; 0.8.23.</description><content:encoded><![CDATA[<p>DeepSeek TUI is vulnerable to remote code execution (RCE) due to the <code>run_tests</code> tool&rsquo;s automatic approval of <code>cargo test</code> execution. The <code>run_tests</code> tool executes <code>cargo test</code> in the workspace with <code>ApprovalRequirement::Auto</code>, meaning it runs without any user approval prompt. The <code>cargo test</code> command compiles and executes arbitrary code, including test binaries, build scripts, and proc macros. A malicious repository can leverage this to execute arbitrary shell commands, exfiltrate credentials, or establish persistence without any user interaction. This vulnerability is amplified by the <code>AGENTS.md</code> file, which is auto-loaded into the system prompt and can instruct the model to proactively run tests at session start. This vulnerability affects versions &gt;= 0.3.0 and &lt; 0.8.23 of the deepseek-tui, deepseek-tui-cli, and npm/deepseek-tui packages.</p>
<h2 id="attack-chain">Attack Chain</h2>
<ol>
<li>An attacker creates a malicious Rust repository.</li>
<li>The repository includes a <code>Cargo.toml</code> file, source code (<code>src/lib.rs</code>), and a malicious test file (<code>tests/integration_test.rs</code>) containing code to execute arbitrary commands, such as exfiltrating data using <code>curl</code>.</li>
<li>The repository also contains an <code>AGENTS.md</code> file with prompt injection instructions to direct the model to run tests automatically.</li>
<li>A user opens the malicious repository in DeepSeek TUI using the <code>deepseek-tui</code> command.</li>
<li>The <code>AGENTS.md</code> file is automatically loaded into the model&rsquo;s system prompt, instructing the model to run tests.</li>
<li>The model calls the <code>run_tests</code> tool, which is auto-approved due to <code>ApprovalRequirement::Auto</code>.</li>
<li><code>cargo test</code> compiles and executes the malicious test code in <code>tests/integration_test.rs</code>.</li>
<li>The attacker receives a callback on their collaborator server, confirming remote code execution.</li>
</ol>
<h2 id="impact">Impact</h2>
<p>Successful exploitation of this vulnerability allows an attacker to achieve remote code execution on the user&rsquo;s machine. A malicious file in the repository (such as <code>AGENTS.md</code>) is auto-loaded into the model&rsquo;s system prompt on session start. This content can contain prompt injection instructions that direct the model to call <code>run_tests</code>. Since <code>run_tests</code> is auto-approved, the full chain from opening the repo to arbitrary code execution requires zero user approval.</p>
<h2 id="recommendation">Recommendation</h2>
<ul>
<li>Upgrade to a version of DeepSeek TUI &gt;= 0.8.23 to patch CVE-2026-45311.</li>
<li>Implement the suggested mitigation of changing <code>run_tests</code> to require approval to prevent automatic execution of potentially malicious code.</li>
<li>Monitor process creation events for <code>cargo test</code> executing shell commands, using a rule such as the one provided below to detect potential exploitation of CVE-2026-45311.</li>
</ul>
]]></content:encoded><category domain="severity">critical</category><category domain="type">advisory</category><category>rce</category><category>prompt-injection</category><category>rust</category><category>supply-chain</category></item></channel></rss>