
Planted Text Tricks AI Agents Into Bad Clicks
Researchers demonstrated a new “agent data injection” technique where attackers plant content (like a review or GitHub comment) that an AI agent mistakenly…
Researchers demonstrated “Ghostcommit,” a method to trick AI code-review assistants using hidden instructions embedded inside an image added in a pull request. The AI agent may later follow those hidden instructions to read sensitive files and leak secrets back into source code, even when the pull request looks normal to human reviewers. The risk depends heavily on the coding tool (“harness”) and its permissions, not just the AI model.
Ghostcommit is a proof-of-concept technique where an attacker submits a pull request containing a harmless-looking image alongside a repository guidance file, such as an AGENTS.md, that tells an AI coding agent to trust the image. The instructions themselves are hidden inside the image file rather than in visible text. A human reviewer scanning the code changes has little reason to open the image, so the pull request appears ordinary. Later, when the AI agent works on an unrelated task and processes that image, it follows the hidden instructions, reads sensitive files, and writes the extracted secrets back into the code in an obfuscated form.
The technique works because prompt injection is no longer limited to text. Images and other multimodal inputs can carry instructions that AI agents interpret and act on, even when nothing in the visible diff looks suspicious. The pull request review process is built around human judgment of code changes, not around inspecting embedded content in attached files. This gap between what a human reviewer checks and what an AI agent later reads creates the opening the attack relies on.
According to the research, whether the attack actually results in secret theft depends heavily on the specific AI coding tool, or harness, and its guardrails and permissions, more than on the underlying language model. The harness decides which files to load, which conventions to trust, and what guardrails to apply, so the same model can behave very differently depending on the tool that runs it. Some harnesses refused to exfiltrate secrets during testing, while others did not.
Organizations using AI coding agents for code review or development tasks should treat pull requests, including any attached images or policy files, as a potential path for attacker-controlled instructions aimed at the AI agent rather than the human reviewer. Practical steps include restricting the secrets and files an agent can access, inspecting non-text attachments before merging, and monitoring agent behavior for unusual attempts to read credentials or config files. Teams should also evaluate coding tools based on their guardrails and permission models, since tool configuration can matter as much as the model itself in determining whether an injection attempt succeeds.
Mirage safely runs attacks like this one against your own team, so you find out what happens before a real adversary does.
Ghostcommit is a technique where an attacker embeds hidden instructions inside an image file added in a pull request, referenced by a repository guidance file, so an AI coding agent follows those instructions during a later task.
Once the AI agent processes the referenced image during a later task, it can be induced to read sensitive files and write the secrets back into the code in an obfuscated form, even though the pull request itself looks ordinary to human reviewers.
No, success depends more on the AI tool or harness and its guardrails and permissions than on the underlying model. Some harnesses refused to exfiltrate secrets in testing while others behaved differently with the same model.
Key defenses include restricting access to secrets, inspecting non-text attachments like images in pull requests, and monitoring AI agents for unusual attempts to read credentials or configuration files.
A pull request introduces a harmless-looking PNG and an AGENTS.md file, and your AI code reviewer says, "Looks good, ready to merge." Here’s the trick: Ghostcommit hides prompt injection inside that PNG. AGENTS.md tells the AI agent to trust the image, and later the agent quietly follows those hidden instructions. In the demo, when the agent later works on a normal task, it reads secret config files and writes those secrets back into the code in obfuscated form. To you, the original PR still looks totally routine. Your move: before you merge, question any PR that adds AGENTS.md or similar guidance files plus unexplained images, and get them reviewed with security, not just code review.

Researchers demonstrated a new “agent data injection” technique where attackers plant content (like a review or GitHub comment) that an AI agent mistakenly…

Scammers on TikTok are impersonating resin artists by reposting stolen videos and telling viewers to “DM to order.” After moving the conversation into direct…

Kaspersky reports an active malware campaign (“OkoBot”) that tricks people into running malicious scripts via a ClickFix-style prompt or by downloading a fake…

This threat trend report describes multiple real-world APT campaigns that rely on social engineering (job offers, fake recruiters, code reviews, and…

Attackers used fake Steam forum replies that looked like helpful troubleshooting steps for real gaming/PC problems. The posts tricked users into running…

AI firm ORO says a suspected North Korean attacker hijacked a real conference contact’s Telegram account and lured an employee into joining a fake Microsoft…