Nx npm malware allegedly weaponized AI agents to exfiltrate data
Two or more independent security outlets describe an alleged Nx npm package attack that used AI code assistants to inventory and exfiltrate developer files. The reports rely on security researchers and vendor blogs, not official adjudications, and describe post-install behaviors and unsafe flags as part of the mechanism.
AI code assistants were weaponized to inventory and exfiltrate developer files.
Key facts
- What
- Two or more independent security outlets describe an alleged Nx npm package attack that used AI code assistants to inventory and exfiltrate developer files.
- Incident date
- Aug 27, 2025
- Who
- Nx
- Failure mode
- Data Leakage
- AI surface
- Code Assistant
- Severity
- High
What happened
Security outlets report that Nx npm packages allegedly invoked AI code assistants (Claude Code, Gemini CLI, and Amazon Q) via post-install actions to inventory and exfiltrate sensitive developer files. Reports mention the use of unsafe flags such as --dangerously-skip-permissions to bypass user confirmations, enabling autonomous data collection and transfer.
What broke inside the model
- 01 · TriggerA request triggers retrieval or context loading.
- 02 · Model stepThe context pulls in another user's content.
- 03 · Control gapNo boundary enforces isolation at the moment of output.
- 04 · FailurePrivate data crosses into the response.
- 05 · ConsequenceOne user sees another's data, and disclosure follows.
One user's content crosses the retrieval boundary into another's response.
The mechanism centers on malicious Nx packages triggering AI code assistants to perform file discovery and exfiltration, with flags like --dangerously-skip-permissions used to bypass prompts and enable automated operations.
What it cost
Sources
Cite this entry
https://failureindex.ai/failures/npm-malware-allegedly-weaponized-agents-exfiltrateAI Failure Index. "Nx npm malware allegedly weaponized AI agents to exfiltrate data" (FI-0240). Realm Labs. https://failureindex.ai/failures/npm-malware-allegedly-weaponized-agents-exfiltrate (indexed Jun 5, 2026).Data fields CC-BY 4.0, prose citation permitted. Incident ID FI-0240. Full dataset at /data.
Note from Realm Labs, the Index steward
How Realm would have caught this
- Prism
- OmniGuard
- AI Detection & Response (AIDR)
Realm can detect when a response is about to emit data that falls outside the bounds of the current user and context, and block or redact it inline, at the moment of generation rather than after the data has left.