Skip to content

The Loom · #9

Your Agent Verified the Pin. It Never Checked the Result.

Plugin4Shell beat SHA pinning in four AI coding agents. Two are patched, one is not, one is retired.

Published October 26, 2026 · written and approved by RiskWoven, sources checked when published

Diagram of a SHA-pinned plugin, result unchecked, linked to four AI coding agents: Claude Code and Codex patched, Copilot no fix, Gemini CLI retired.

Thread

On 18 September, Help Net Security reported Plugin4Shell, a zero-click remote code execution flaw that AIR Security found in May and disclosed to the four vendors in June. It affects Claude Code, Codex, GitHub Copilot and Gemini CLI. Anthropic patched Claude Code in version 2.1.179 on 17 June. OpenAI patched Codex in version 0.146.0 on 12 August. Google confirmed on 4 August that Gemini CLI would be deprecated rather than patched, so every existing install stays exposed. As reported, Microsoft had shipped no fix for GitHub Copilot. Anyone running a coding agent that installs plugins from a marketplace is in scope, and the attack needs no mistake by the user. That is what makes it a governance problem as well as a patching one: the control was in place, followed and reviewed, and it still did not protect anyone.

Pattern

SHA pinning is the control many teams point to: lock a plugin to the exact commit that someone reviewed. Plugin4Shell shows where it breaks. When a branch and a commit carry the same name, git checkout prefers the branch. An attacker who controls a plugin's repository creates a branch named after the pinned hash and makes it the default. The agent's background update resolves the pin to that branch and runs malicious code. According to AIR Security, none of the four agents verified that the checkout landed on the pinned commit. Auto-update, the default in Claude Code and Codex, turned it into a zero-click attack. Marketplaces cannot close the gap, because the pin is resolved on the client.

The supply chain around it is already proven. Help Net Security notes earlier research where a test plugin reached more than 26,000 agents before removal, and a related study that found 925 hijacked skills reaching 134,000 agents.

Knot

The policy line reads "plugins are pinned to reviewed versions", and on paper it passes. But the only party checking the pin was the agent being fooled. A control whose evidence comes from the thing it protects is a promise, not proof. An auditor asking for evidence would want a check that runs outside the agent, such as confirming that the resolved commit equals the pin, which is the fix AIR Security proposes for the agent side. Under a management-system standard such as ISO 42001 the ask is the same: show the record, not just the policy. A policy that says pinned, with no record that the result was verified, will not survive a curious auditor, and it did not survive this attack either.

Two more knots sit underneath. First, patch status differs by vendor, and a retired product means indefinite exposure. AIR Security advises Gemini CLI users to migrate, which is a vendor lifecycle decision your third-party register should already anticipate. Second, the same auto-update setting that delivers a fast patch also delivered the attack silently. Turning it off is not the answer either, because unpatched agents stay exposed. The answer is knowing what runs where, and that starts with an inventory of agents, versions and plugins.

Stitch

This week, ask three things.

  1. Which coding agents and plugins run in our environment, and at which versions? If nobody can list them, that is the finding.
  2. Do we meet the patched versions where they exist (Claude Code 2.1.179 or later, Codex 0.146.0 or later), and what is the plan for the two tools with no fix?
  3. For each control we call "pinned" or "approved", where does its evidence come from, and can the control itself influence it?

A free scan at riskwoven.com/assess shows where your AI governance evidence is thin, in about twelve questions.

Sources

Share on LinkedInRun the free 12-question scan
Post text to copy
Your coding agent verified the pin. It never checked the result.

Plugin4Shell (AIR Security, reported 18 Sep) beat SHA pinning in Claude Code, Codex, GitHub Copilot and Gemini CLI. Claude Code and Codex are patched. Copilot had no fix as reported. Gemini CLI was retired instead of patched.

The lesson is not about one vendor. A control whose evidence comes from the thing it protects is a promise, not proof. Do you know which agents and plugins run in your environment, and at which versions?

Full issue: https://riskwoven.com/loom
#AIGovernance #CyberSecurity #AISecurity