A pull request title looks like the least dangerous text in software. In October 2025 it was enough to take over Anthropic’s Claude Code Security Review action, and the case shows why AI agent security depends on permissions more than on prompts. The action dropped the title directly into the agent’s prompt. The agent had no tool limits and ran in a process that carried over the job’s secrets, among them GITHUB_TOKEN and ANTHROPIC_API_KEY.
A crafted title made the agent run commands such as ps. The output came back as a PR comment.
Three agents, one pattern
Follow-up work from April 2026, called “Comment and Control,” compromised two more agents. For the Gemini CLI Action, an issue with an invented “Trusted Content Section” convinced the agent to publish its GEMINI_API_KEY in a public comment. GitHub’s Copilot Agent obeyed commands tucked into an HTML comment, invisible on the rendered page, after it was assigned the issue. It then pushed its process list, base64-encoded, into a PR.
Lead researcher Aonan Guan named the common cause: for these agents, injected text counts as ordinary input they were built to handle. Every team chose to deploy the agent, chose to hand it credentials and chose to aim it at text that anybody could author.
Exposure depends on setup. By default GitHub Actions withholds secrets from fork pull requests. Repositories that open that door, such as through pull_request_target, do exist. A follow-up preprint reports that 4,714 GitHub workflows and eight n8n templates could be hijacked. Bounties from the three vendors came to $100, $1,337 and $500. None issued a CVE or a public advisory, which means anyone pinned to a vulnerable version could stay unaware.
How often the model falls for it
Security people call this the confused deputy, a term from a 1988 note by Norm Hardy. The agent acts with your authority on someone else’s wishes. GitLab’s CVE-2026-96893, fixed on 12 October 2026, let an authenticated user inject crafted content into agent instructions and cause commands attributed to other users.
A preprint called INFUSE measured the odds. Across 19 models and 41,824 adversarial runs, attackers planted instructions in files, terminal output and other material an agent encounters mid-task. On average 19.6% of attacks worked, and the rate swung from 3.2% to 41.9% depending on the model.
The study also tested a defence many engineers dismiss: telling the model to ignore instructions found in content. It was the strongest prompt-level defence tested. The tested version wraps the task, says to disregard instructions that show up later, and repeats the warning after each observation. In the stress-test subset it lowered average attack success from 58.2% to 14.3%, whereas ready-made guard models left it around 44%. The authors caution against generalizing to the whole benchmark, and task completion moved anywhere from a 42-point improvement to a 17-point drop.
It’s cheap and worth doing. It’s still no foundation. Roughly one attack in seven still landed, and the study didn’t test adaptive attackers who tune their input to the target model.
Assume the model has been fooled
Sound AI agent security starts from that assumption.
Since the success rate keeps shifting, the safer plan is to treat it as 100%. Then check which damage a completely hijacked run could do with the tools it has. Take an invented but typical on-call triage agent that reads error logs, counts affected customers and posts to a channel. Log lines contain whatever users typed, so it reads attacker-writable text on step one. It also holds private data and a way to send data out. Simon Willison calls that combination the lethal trifecta, and it usually builds up one reasonable tool at a time.
Blocklists don’t fix it. Block env, printenv, ps, curl and nc, and a shell can still read the token with echo or export. Anthropic’s patch blocked ps, yet cat /proc/*/environ yields identical data. Guan calls blocklisting whack-a-mole.
Allowlists leak through what they allow. CVE-2026-54316 covered a host Claude Code approved ahead of time, huggingface.co: requests to repositories an attacker controlled could smuggle data out. Slack must fetch every URL in a message to preview it, so even a link in a post to the right channel can leak data. Apps can close that route by turning off unfurl_links and unfurl_media.
What to change this week
These steps give AI agent security a floor that doesn’t depend on the model behaving.
- Replace free-text tools with typed ones: a count_affected(service) call in place of query_db, and a post_triage call that accepts only a service, a severity enum and an affected-customer integer in place of post_slack.
- Remove http_fetch entirely if no field needs it.
- Patch the tool layer like any dependency. LiteLLM’s CVE-2026-59822 let a fabricated Authorization header skip key validation and reach MCP tooling.
Typed tools have a price. The on-call engineer no longer gets a free-form explanation, and the agent can’t run improvised queries. Some teams will decide that’s too much. They can route free text to a human-only view and make the trade knowingly, tool by tool.
One gap stays open. A hijacked agent can lie inside a permitted field, and “low” is always a valid severity. Permissions limit the damage, but a person still has to check the output that matters.
Source: hackernoon.com