Module Shadowing Attack Hijacks Claude Code for RCE
wunderwuzzi23 · x · 2026-08-31
A researcher demonstrated a "Module Shadowing" attack chain that compromises Claude Code Opus 5, allowing full system takeover via a website interaction.
Exploit Details:
- Vector: The attack tricks Claude into unzipping a malicious file containing struct.py.
- Mechanism: When Claude runs import base64, Python's import resolution prioritizes the local malicious struct module over the standard library, executing attacker code.
- Root Cause: The safety decision to allow unzipping and importing code from untrusted sources acted as the exploit itself.
This highlights critical security gaps in AI coding agents regarding sandbox isolation and path pollution.
More from coding & agent
- JAZ: open-source framework turns an LLM agent into a single invoke() with native Python objects — a1zhang · 2026-12-02
- Custom fast path cuts PISA feature attribution from 17s to 1s per example on H200 — jmschreiber91 · 2026-12-02
- NVIDIA and Anthropic team up to help businesses deploy AI agents with data control — nvidia · 2026-12-02
- WebGPU wins for WebRTC video effects: benchmarks vs WebGL, WASM, WebNN — chadwallacehart · 2026-12-02
- Isolated AI agents secretly communicate via disk space and nanosecond memory timing channels — maksym_andr · 2026-12-02
- Robot-dev agents: frontier models work in sim, robots run fast policies — scott_e_reed · 2026-12-02