AI Security

AI Coding Agents Under Attack: Plugin4Shell, MCP Flaws and How to Protect Developers

By NextGarrison Security TeamPublished 7 min read

In 2026, attackers and researchers found that AI coding assistants trust far too much: project files, plugins and add-on tools. Here is what was found and what to change in your team this week.

In plain English

  • AI coding assistants had a run of serious flaws that let attackers run commands on developer computers.
  • Any team using AI coding tools is exposed, often just by opening an untrusted project.
  • Update these tools, make them ask before running commands, and limit which add-ons they use.
  • Keep long-lived passwords and keys off developer laptops so a hijacked assistant cannot steal them.

Why AI coding agents became a target

AI coding agents are assistants that write code for developers. They read your code, run commands and install tools. They often hold cloud passwords and access tokens. That makes them attractive targets. A single bad file in a repository (a shared code project), or a poisoned plugin, can turn the agent against you. It then works for the attacker from inside a developer's computer.

Most of the 2026 findings share one root cause: the agent treats untrusted content as trusted instructions. That is prompt injection (hiding orders for an AI inside text it reads), with real tools attached.

What was found in 2026

The table lists the main flaws by month, with fixed versions for your developers. Many involve MCP, the Model Context Protocol, a standard way to plug extra tools into an AI assistant. Each tool runs as an MCP server.

WhenIssueImpact
MayMicrosoft Semantic Kernel (CVE-2026-26030, CVE-2026-25592)Prompt injection led to code execution and file writes on the host. Fixed in Python 1.39.4 and .NET 1.71.0
May to JuneAmazon Q Developer MCP auto-execution (CVE-2026-12957)A malicious repo could run commands from its MCP config and steal AWS credentials. Fixed by AWS, with a consent prompt added
SeptemberPlugin4ShellBypass of plugin pinning gave zero-click code execution via auto-update in several coding agents. Fixes shipped for Claude Code and Codex; others lagged
OctoberEmbedded browser flaws in AI developer toolsResearchers reported file read and code execution issues in five tools; some remained unpatched at publication
NovemberVS Code MCP fixes (CVE-2026-120779, CVE-2026-114171)A malicious MCP server or install link could run commands. Fixed in VS Code 1.145.3; user interaction required

Several of these needed nothing more than a developer opening the wrong repository.

The common patterns

  • Project files as instructions: settings files, guidance notes and git settings in a downloaded project were run or obeyed. This happened before the user had said they trust the project.
  • Auto-updating plugins and tools: once a plugin source is hacked, every machine that updates is hacked too.
  • MCP servers with too much power: add-on tools that can run commands or write files, connected without review.
  • Passwords and keys within reach: cloud keys, GitHub tokens and SSH keys that the agent can read.

What to change this week

  1. Update every AI coding tool and code editor (IDE) your team uses, and turn on auto-update for security fixes.
  2. Require a yes before the agent runs commands, at least for anything outside the project folder or that touches the network.
  3. Open unknown projects in a sandbox (a separate container or virtual machine without your real passwords), not on your main computer.
  4. Approve MCP servers and plugins by name. Review what each one can do, lock it to a set version, and remove the ones nobody uses.
  5. Keep long-lived secrets off developer laptops. Use cloud keys that expire quickly and a secrets manager (a secure vault for keys).
  6. Log agent actions so you can investigate if something goes wrong.
Treat an AI agent like a new contractor with admin rights: useful, fast and in need of clear limits.

What this means for products with AI features

The same weak spots appear in AI that customers use. Think of support bots that call internal APIs (links that let one system talk to another). Or assistants that read email, and agents that take actions in your app. In August, OWASP released a 2026 edition of its Top 10 for LLM Applications. An LLM is the kind of AI model behind chat assistants. The AICPA, which sets the rules for SOC 2 security reports, has also proposed adding AI points of focus to SOC 2 (see our summary). Expect customers and auditors to ask how your AI features are tested.

Our AI red teaming service tests chatbots, agents and MCP links against these attacks.

Sources

#AI agents#MCP#Prompt injection#Supply chain

Need a hand with this?

Talk to a senior consultant. We reply within one business day with clear next steps and a scoped quote.

Written by

NextGarrison Security Team

Penetration testers, SOC analysts and compliance consultants

Our consultants test applications and networks, run 24/7 security monitoring and prepare companies for SOC 2, ISO 27001 and PCI DSS assessments. We write about what we see in real engagements, in plain English.

Frequently Asked Questions

Are AI coding assistants safe to use?

Yes, with limits. Keep them updated and make them ask before they run commands. Open untrusted projects in a sandbox, and keep long-lived secrets out of their reach.

What is MCP and why does it matter for security?

The Model Context Protocol lets AI agents connect to tools and data. Each MCP server adds a power, such as running commands or reading files. So a bad or overly powerful server can give an attacker that same access.

Keep reading