Hijacked coding assistant session recommends poisoned package; Shai-Hulud spreads across about 100 repositories
An attacker hijacked a developer's active AI coding assistant session; the assistant recommended a poisoned package, and once it was accepted the Shai-Hulud worm spread across about 100 internal repositories.
Case study 1 in Mandiant's September 2026 AI risk and resilience report. Mandiant says a threat actor compromised a SaaS provider and hijacked an active coding assistant session on a developer's workstation. The assistant recommended an external package the attacker had poisoned. After the recommendation was accepted, the attacker used the session to install an infostealer via a poisoned PyPI package, took GitHub OAuth tokens and deployed the Shai-Hulud worm across about 100 internal repositories, taking repository secrets and product source code. A package in the company's own namespace was then poisoned and a second employee pulled it. The report does not name the victim or the assistant, give a date, or say how the session was taken over. A person accepted the recommendation, so the assistant's own actions are limited to the recommendation.
- Unknown
- Not disclosed
- Not disclosed
- Not disclosed
What happened
Attacker compromises a SaaS provider and hijacks an active coding assistant session on a developer's workstation
Mandiant does not say how the session was taken over.
The assistant recommends installing a poisoned external package and the recommendation is accepted
The report does not say who accepted it; the secondary write-ups describe it as the developer accepting.
Attacker uses the live session to install an infostealer through a poisoned PyPI package and take GitHub OAuth tokens
The worm then ran across about 100 internal repositories, taking repository secrets and product source code.
A package in the organisation's official namespace is poisoned and a second employee pulls it
A secondary downstream infection.
Mandiant publishes the case in its AI risk and resilience report
Victim and assistant not named.
Agent failures
Hijacked by an attacker, Supply chain compromise, Credential misuse, Data exfiltration
Hijacked by an attacker
Supply chain compromise
Credential misuse
Data exfiltration
How it was found
Found first by not disclosed, from not disclosed
- Not disclosed
- Not disclosed
- Not disclosed
Not disclosed. Mandiant says it investigated the intrusion but not how it was first noticed or by whom.
What is publicly known
0 of 12 fully public
| Item | Public? | Detail | Sources |
|---|---|---|---|
| Unknown | The assistant product and model are not named. | ||
| Unknown | Not stated. | ||
| Weak | Mandiant's recommended hooks and allowlists imply none were enforced; what was in place is not stated. | ||
| Unknown | Not stated. | ||
| Unknown | What the developer was doing in the session is not described. | ||
| Weak | An AI coding assistant on a developer workstation with reach to PyPI and GitHub OAuth tokens; product, tools and permissions not named. | ||
| Weak | Mandiant recommends restricting workstation egress, implying dependencies could be fetched directly; the actual setup is not described. | ||
| Unknown | No session transcript or logs published. | ||
| Unknown | Not stated how it was detected. | ||
| Partial | About 100 internal repositories hit, repository secrets and product source code taken, a second employee infected. Victim anonymised; no customer impact stated. | ||
| Weak | Mandiant describes the chain from session hijack to poisoned recommendation but does not say how the session was taken over. | ||
| Weak | Mandiant lists recommended controls. It does not say what the victim changed. |
Controls that apply
Govern
Protect
Detect
- All controls →