NewsTradingSentimentCalendarCommunityBriefing
Tech

Plugin Swap Flaw Exposed in Four AI Coding Agents

By Tech Desk · 2026-09-18 · 2 min read
A tangled ball of yarn with a single loose thread being pulled out
Illustration: Tradingbird

A security gap allows attackers to replace trusted AI coding tools with malicious code, bypassing version locks on non-GitHub repositories.

Security researchers have identified a vulnerability in four popular AI coding agents that allows attackers to replace legitimate plugins with malicious code. The flaw exploits a weakness in how these tools verify the source of their add-ons, potentially compromising the user's local environment without their knowledge.

The issue was disclosed by security firm Air Security, which noted that Anthropic and OpenAI have already released patches, while GitHub Copilot remains unfixed and Google has chosen not to address the flaw in its Gemini CLI. The risk is particularly acute for users who rely on automated updates, as the replacement can happen silently in the background.

Version locks fail on certain hosts

AI coding agents typically secure themselves by locking plugins to a specific version identified by a unique code string, or commit hash. However, Air Security found that these agents fetch the code but never verify that the downloaded content actually matches that hash. This creates a gap where the software believes it is installing a safe, reviewed version when it is actually receiving different code.

The trick relies on how some code hosting platforms handle branch names. If a repository owner creates a branch that looks like a valid commit hash, the agent may interpret the request for that hash as a request for that branch. Since the branch can point to any code the owner chooses, the agent installs the malicious payload while still reporting that it is on the locked, safe version.

GitHub restrictions limit the exploit

The attack does not work universally. GitHub, the most popular code hosting platform, prohibits branch names that resemble commit hashes. This restriction means that plugins installed from GitHub repositories are generally safe from this specific branch-naming trick. Most default plugin catalogs for Claude Code and Copilot are hosted on GitHub, which significantly reduces the risk for the average user.

However, the flaw persists on other platforms like Bitbucket or private enterprise servers that allow such naming conventions. The Hacker News verified that while the primary risk is limited to these alternative hosts, the Gemini CLI faces a different but related issue where a specific branch name can bypass GitHub's protections, leaving that tool vulnerable even on standard repositories.

Automatic updates increase exposure risk

The danger is amplified by the default setting for automatic updates in Claude Code and Codex. These agents can refresh their installed plugins in the background without asking the user. If a trusted plugin is swapped for malicious code during an update, the user may not realize their environment has been compromised until unauthorized actions occur.

Because the verification happens on the user's machine rather than the marketplace, the fix must come from the agent software itself. Users of affected versions should update their tools immediately, especially if they install plugins from non-GitHub sources or have enabled automatic updates for external repositories.

Based on reporting by The Hacker News, compiled by the Tradingbird desk.

Read next

More in Tech

More from the Tech desk

All desk stories
  • A high-voltage electrical substation with large transformers and insulators standing in an open field
    Illustration: Tradingbird

    H&MV Engineering to Create 1,000 US Jobs for AI Power Needs

    As artificial intelligence strains the electrical grid, a major engineering firm is expanding its US footprint to bridge the gap between digital demand and physical infrastructure.

    2026-09-18
  • A wooden gavel resting on a polished desk surface
    Illustration: Tradingbird

    Congress Faces Pressure to Regulate AI Amid Safety Fears

    Lawmakers in Washington are responding to growing public anxiety about artificial intelligence, with new legislation proposed to mandate safety testing before models are released.

    2026-09-18
  • A split view of a wooden desk surface divided into four quadrants, each holding a different style of keyboard and mouse: a sleek aluminum set, a white minimalist set, a black mechanical set, and a compact grey set.
    Illustration: Tradingbird

    Choosing Your Computer's Brain: A Guide to the Big Four

    The operating system you choose dictates what your computer can do, how it feels to use, and what it costs. While the market offers many niche options, four systems dominate the desktop landscape, each with specific strengths and significant trade-offs.

    2026-09-18