Cline AI Coding Agent Vulnerable to Prompt Injection via .clinerules Files
Security researchers at Mindgard AI disclosed that Cline, an AI coding agent, is vulnerable to prompt injection attacks through malicious directives in .clinerules files that can force execution of unsafe commands and arbitrary code on a user's system.
What happened
Malicious instructions planted in Markdown files within a project's .clinerules directory can coerce Cline into executing unsafe commands without approval.
An attacker can leverage this vulnerability to execute arbitrary code in the context of the user running VSCode.
Reported impact
Exploitation requires nothing more than opening a malicious source repository and asking Cline to analyze it.
Index analysis
The vulnerability exploits Cline's trust in source code repository contents and its responsiveness to instructions embedded in configuration files.
Classification
Sources and evidence
This record was researched and written by the Index, based on the following original reporting.