Tag: GitHub Actions

AI Coding Agents That Ship Their Own Code: Early but Real, If a Human Owns the Merge

AI Coding Agents That Ship Their Own Code: Early but Real, If a Human Owns the Merge

On February 17, 2026, at 3:26 AM Pacific time, someone published cline@2.3.0 to npm. Nobody at Cline pushed that button. The token came from a chain that started with an AI triage bot reading a GitHub issue title, and the package sat on npm for about eight hours. Its postinstall line only installed another tool, and Cline says no user data was touched. The next attacker won’t be that polite.

It matters more this week because agents got closer to the merge button. On November 23, 2026, Anthropic launched Claude Ship: a review agent (generally available), PR Steward, a beta that fixes failing CI and review comments by pushing commits, and Claude Approvals, a beta that can post an approving review under a policy file in your repository. GitHub has been moving the same way. Claude Ship is my example because it’s the newest; GitHub’s Copilot cloud agent and OpenAI’s Codex sit in the same category.

At a glance

What it isAI agents that commit, push, open pull requests, answer review comments and fix CI without a person typing each step, and now sometimes approve
KindTrend
MaturityEarly adoption (agent-drafted pull requests are common; agent approval is in beta or preview)
Who should careAnyone who owns a GitHub or GitLab organization, CI/CD secrets, branch protection or a package you publish
VerdictEarly but real
Read time7 minutes

What’s actually changing

The volume is real. GitHub’s Octoverse, published October 28, 2026, counts a pull request as agent-started when its first draft came from a coding agent GitHub can detect. On that definition, agents went from 17% of pull requests in March 2026 to more than 40% in September, about 110 million that month. GitHub also says agent pull requests merged within two weeks at 90% in September, against about 86% for the rest. Keep in mind who is counting: GitHub sells one of these agents.

The second change is the approval step. On September 1, 2026, GitHub put Copilot code review approvals into public preview: off by default, but once on, Copilot’s approval counts toward the repository’s required approvals. Anthropic’s docs say the same of Claude Approvals: its approving review can meet a GitHub rule that requires one approval. In March, GitHub also added a setting that lets admins skip the human approval before workflows run on Copilot’s pull requests. The default still asks a human.

The third change is the attack record. Adnan Khan disclosed the Cline chain on February 9, 2026: any GitHub user could trigger the triage bot, which had shell access, the issue title went straight into the prompt, and a shared Actions cache let that job poison the release job holding the npm token. Cline then deleted the wrong npm token, which is how the February 17 publish happened. On April 15, 2026, Aonan Guan and two Johns Hopkins researchers showed “Comment and Control”: crafted PR titles, issues and hidden HTML comments got Anthropic’s security review action, Google’s Gemini CLI action and GitHub’s Copilot agent (once a victim assigned it the issue) to leak keys or tokens. GitHub called its part an architectural limitation. In June, GMO Flatt Security and Microsoft published two more ways to pull secrets out of Claude’s GitHub Action. Each reported path was patched, though the Flatt researcher describes follow-up bypasses from February to April.

Timeline of six dated events from February to November 2026: the unauthorized Cline npm publish, GitHub's option to skip workflow approval for Copilot, the Comment and Control disclosure, Copilot code review approvals, Octoverse reporting agents start more than 40% of pull requests, and the Claude Ship launch
2026 in six dates: agents gained the approval path while researchers kept pulling secrets out of them. Sources: Adnan Khan, Cline, GitHub, Aonan Guan, Anthropic.

The best independent test I found is GitInject (arXiv v2, November 2, 2026), which ran 11 attack scenarios against live GitHub Actions workflows from Anthropic, OpenAI, Google and Cline. Every provider fell to at least one high-severity attack in the tested setups. The worst class was a CLAUDE.md, AGENTS.md or GEMINI.md file in the attacker’s branch, loaded as trusted instructions.

How it works

Every one of these agents reads text from places anyone can write to (issue titles, PR bodies, comments, CI logs, config files in the branch), decides with a model, and acts with credentials: a GitHub App token, a CI secret, an API key. The old pipeline had the same inputs and tokens. What’s new is that a model, not a person, sits between the untrusted text and the token, and a model treats that text as context to follow. OWASP’s Top 10 for Agentic Applications (December 9, 2025) names the pieces: ASI01 Agent Goal Hijack, ASI02 Tool Misuse, ASI03 Identity & Privilege Abuse, ASI04 Agentic Supply Chain Vulnerabilities.

Before and after table comparing a human-driven pull request with an agent-driven one across five steps: who writes the change, who reads untrusted text, where credentials live, who fixes CI, and who approves
What moves when an agent ships the code: the same pull request, with the untrusted text and the credentials now in front of a model.

The platforms answer with the same few controls. Copilot cloud agent pushes only to its own branch unless started on an existing pull request, can’t approve or merge its own work, ignores comments from users without write access, and needs one more approval when a pull request isn’t attributed to a person. Anthropic keeps PR Steward’s GitHub token outside its sandbox and refuses approvals, branch protection edits and tag pushes at its service. Merging, auto-merge and force-push are left to your branch rules plus a text match and a model’s judgment, and the docs admit a command written another way can pass both. Codex blocks internet access during the agent phase by default. GitHub’s Agentic Workflows go furthest: a read-only agent job, writes staged and checked after it exits, and zero access to secrets as the design goal.

Where it helps, and where it doesn’t

Real wins. Fixing red CI and stale review comments is boring work, and agents do it fast. Anthropic says merged pull requests on its Claude Code team more than doubled from June to September while the share reverted fell by more than 40%, an internal claim with no method published. Copilot’s commits are signed, co-authored by whoever assigned the work, and linked to a session log, which to me beats a shared personal access token.

Real limits.

  • Prompt injection isn’t fixed, it’s fenced. In Comment and Control, Anthropic said its security review action “is not designed to be hardened against prompt injection.” Flatt Security’s researcher says he has reported about 50 permission bypasses to Anthropic. Vendors patch each path. The class stays.
  • Bot approvals can quietly replace the second human. Anthropic’s docs list the ways a pull request can merge without human review: seats: 0, seats: 1 that the author fills, a machine user counted as a person, files no rule covers. A policy condition that reads a classifier can also be steered by the PR author’s own text.
  • Auto-merge closes the loop. The docs warn that with auto-merge or a merge queue and a policy that needs no person, “a change can merge without anyone acting.”
  • Review is already fast. A Notre Dame study of 33,596 agent pull requests (2025 data) found a median review time of 0.11 hours for non-security agent PRs, against 3.92 hours for security ones. The authors stress this measures reviewer scrutiny, not whether the code was secure.
  • Controls cost something. In GitInject’s tests, an author-association filter let 0 of 9 attacks through but broke one of five normal tasks, and config-file judgment manipulation survived every control tested. PR Steward has no spend limit until you set one.

What it means for you

Small team / SMB: evaluate, with one rule. An agent fixing CI on your own pull requests is fine. One that runs on events strangers can create (issues, fork PRs, comments) while holding a publish token is not. First step: search your workflows for AI actions and settings such as allowed_non_write_users: "*", and pull publish secrets out of any job that feeds issue or PR text to a model.

Mid-size or enterprise: start now on the controls, pilot the agents. Write down your two-person rule before a policy file rewrites it. On default branches, require one approval from a human who isn’t the author, keep agent apps off every bypass list, dismiss stale approvals, and leave the workflow-approval gate for agent PRs on. Apply the Agents Rule of Two that Microsoft’s post recommends: no workflow should read untrusted input, hold secrets and write or call out at once. Ask any vendor:

  • Where does the token live, and can the agent’s own process read it?
  • Whose comments and which repo files reach the model, including CLAUDE.md or AGENTS.md from the PR branch?
  • Can the agent push to workflow files, other branches, or tags?
  • Can its approval count toward required reviews, and can I turn that off centrally?
  • Which audit events show what the agent read, ran and pushed?

Practitioners and learners: start now. Read the Clinejection write-up and the GitInject defense table. Then build a throwaway repo with an AI action, open an issue from a second account, and watch what the agent does.

My take

Early but real. The agents work and the volume is huge, so “wait” isn’t serious advice. But the security model is still patched one bypass at a time, and the newest step, a bot approval that satisfies branch protection, changes something we’ve treated as fixed for years: the second person on the merge. I don’t object to a model reviewing code. I object to it counting as the human.

I’d move this to Ready now if platforms made “one human who isn’t the author” the enforced default on agent-written pull requests and kept secrets out of agent runtimes by design, the way GitHub’s Agentic Workflows try to. I’d call it Overhyped if independent data showed agent PRs reverting or breaking things more often than human ones. Prediction, and this is opinion: by the end of 2027 at least one widely used package will be published with malicious code through an AI agent that approved or merged its own change, and that incident, not a standard, will make human-only approval the default.

Further reading on netsec101

Sources