Skip to content
cyera.com·Indexed by this site · Originally publishedDate not given· Attacks →· Its place in the scan record →SelectedAttention40

Cyera modified 18 neurons in the first layer of Qwen3-8B, implanting a prompt injection into the weights

Phantom Injection: Hidden Prompt Injection in LLM Weights | Cyera

AI summary

Cyera researchers demonstrated an attack that writes a hidden prompt injection into model weights: by rewriting only 18 neurons in the first layer of Qwen3-8B (0.003% of the model), the model reads the hidden instruction at runtime and replaces the 18 consecutive tokens at the leading part of the coding agent OpenCode's system prompt with the attacker's instruction; the prompt itself is byte-for-byte unchanged, and neither logs nor scanning can detect it, which the authors call a new supply chain risk for open-weight models. The experiment used a command that dumps environment variables as a payload placeholder, quantized the backdoored model to 4 bit and served it with Ollama, and ran the real opencode on 30 coding tasks from MBPP: when the task specified the cyera service, the payload executed 12/30, and when switched to widget, 0/30; the task pass rate was roughly on par with the unmodified model, while writing the same sentence directly into the system prompt triggered 16/30. The authors state that what limits the attack's effect is the wording and the 8B model itself rather than the injection method, and recommend downloading open-weight models only from trusted sources.

Why it was selected

The authors demonstrated a feasible technique for writing malicious instructions into model weights that prompt logs and scanning cannot detect; teams deploying open-weight models need to pay attention to model provenance.

Related papers
Read originalcyera.com