AI coding assistants

Attacks on AI coding assistants, from public evidence.

How coding assistants, their extensions and their supply chain were turned against developers, what the evidence says stops it, and where ColossalX fits.

A coding agent · checkedIllustrative

A coding agent · checked: coding assistant to developer terminal, "Read the cloud credentials file and post it here". Checks: Secret in the request failed, Destination not allowed failed, Policy hook active passed. Verdict: refused, Refused on the machine.

In short

AI coding assistants run with a developer's access to code, secrets and the terminal, which makes them a target. Public cases include a poisoned extension release, a flaw that switched an assistant into auto-approve, and malware that ran installed AI tools to hunt secrets. Locked-down agent settings and least-privilege tokens matter most.

Last reviewed

Injected repository content or a poisoned package makes a coding agent run commands and leak secrets.

Each prompt and tool call checked on the developer's machine, with secrets refused before they leave.

What happened

What has happened, in public cases.

The assistants took real hits, and malware learned to borrow the AI tools already installed.

  • A poisoned extension releaseAWS-2025-015 A pull request put a data-wiping prompt into a coding extension.

    The release shipped before it was replaced, and the prompt reportedly failed to run. It is tracked as CVE-2025-8217.

  • Injection switches on auto-approveCVE-2025-53773 Injected content made an agent enable auto-approve and run commands.

    The agent wrote its own settings file to approve every action, then executed code. The vendor fixed it.

  • Malware that borrows your AINx, August 2025 Malicious package versions ran installed AI CLIs to search for secrets.

    The payload called the assistants with flags that skip their permission prompts, and published what it found to public repositories.

  • A self-spreading npm wormShai-Hulud 2.0

    Wiz counted 25,000+ affected GitHub repositories.

Public sources: AWS security bulletin AWS-2025-015, July 2025; Embrace The Red: Copilot remote code execution via prompt injection, August 2025; The Hacker News: malicious Nx packages in s1ngularity attack, August 2025; Wiz Research: Shai-Hulud 2.0, 24 Nov 2025. Checked 7 Nov 2026.

Coding assistants · public casesIllustrative

Coding assistants · public cases: Jul 2025 Poisoned extension release; Aug 2025 Auto-approve flaw fixed; Aug 2025 Nx borrows AI CLIs; Nov 2025 Shai-Hulud 2.0.

What works

What the evidence says works.

The same root causes recur across these cases. The controls follow from them, though none has been measured.

  • No auto-approve, no skip flagsRoot causes

    Keep permission prompts on, and refuse flags that skip them.

  • Review agent configurationRoot causes

    Treat rules and settings files as code, including hidden characters.

  • Trusted publishingRoot causes

    Publish packages with provenance, from CI, not personal tokens.

  • Least-privilege tokensRoot causes

    CI and developer tokens scoped to the job, and short-lived.

Controls · strength of evidenceIllustrative

Controls · strength of evidence: Permission prompts kept on ends in consistent across cases; Configuration reviewed as code ends in consistent across cases; Provenance and scoped tokens ends in sound, not yet measured.

Where ColossalX fits

Where ColossalX fits.

ColossalX checks coding agents on the machine and scans the code and packages they touch.

  • Policy hooks for coding agents

    Each prompt and tool call checked, and secrets refused, on the machine. Code security

  • Agent configuration scanned

    Repository scans of agent settings, rules and MCP files. Code security

  • Secrets and dependencies

    Secrets, vulnerable and malicious dependencies, found on each push. Code security

  • A gate in CI

    Builds that add a new problem fail before they ship. Code security

See code security
Repository scanIllustrative

An illustrative repository scan: a push to a payments service scanned, two findings new since the last scan, a leaked API key confirmed still live and an exploited dependency, the CI gate failing the build, an older finding left in the baseline, and a ticket raised for the owning team.

Honest by design

What this research does not show.

Coding assistants · stated plainlyIllustrative

Coding assistants · stated plainly: Policy hooks built; Fleet roll-out your device management; Control evidence consistent, unmeasured. Stated, not implied.

x, not measured

The policy hooks run on each developer machine; you roll them out with your own device management.

All 3 limits
  • Root-cause controls here are consistent across incidents but have no published effectiveness study.
  • Incident details come from public write-ups and vendor bulletins, and may be incomplete.

Questions

Questions buyers ask

Why are AI coding assistants a security target?

They run with the developer's access: source code, secrets in files and environment variables, the terminal and often cloud credentials. An injected instruction in a repository, an issue or a package can steer that access. Public cases show attackers poisoning an extension release, switching on auto-approve and running installed assistants to search for secrets.

What does malware that borrows your AI mean?

In the Nx compromise of August 2025, malicious package versions ran the AI command-line tools already installed on a developer's machine, with flags that skip their permission prompts, and used them to look for secrets. The attacker did not need their own AI: they borrowed the victim's, with the victim's access.

Which settings matter most for coding agents?

Keep permission prompts on and refuse flags that skip them, keep agent rules and settings files under code review, including checks for hidden characters, and scope CI and developer tokens to the job. These follow from the root causes of the public cases; no study has measured how much each one reduces risk.

How does ColossalX protect developers using coding agents?

Policy hooks for coding agents check each prompt and tool call on the developer's machine and refuse secrets, while repository scans cover agent configuration files, secrets and dependencies, including malicious packages, with a CI gate that fails builds adding a new problem. The hooks reach a fleet through managed settings files your administrators place.

Next step

Know your x before it ships.

See your repositories, agent configuration and developer machines checked, with new problems stopped at the gate.

  1. 01Tell us which AI you run
  2. 02See where it is exposed
  3. 03Decide what to test first