A new paper from MIT cuts straight to the heart of why prompt injection keeps working. The reason is not that attackers are cleverer than defenders. The reason is that language models cannot tell who is speaking.

The paper, "Prompt Injection as Role Confusion" (arXiv:2603.12277v4), traces the vulnerability to a single structural failure. Models infer the source of text from how it sounds, not from where it actually comes from. A command buried in a webpage hijacks an agent because it sounds like a user instruction. The model treats it as one. This is not a surface-level trick. In the model's internal representations, text that sounds like a trusted source occupies the same neural space as text that actually is one.

The authors call this role confusion. And it reframes prompt injection from an arms-race exploit into a measurable consequence of how models represent authority.

The Tag Illusion

Modern LLMs try to solve the who-is-speaking problem with tags. <user> means this is external. <tool> means this is data, not an order. <assistant> means this is my own output. <reasoning> means this is my own thought, trust it.

These tags create what the paper calls an instruction hierarchy. System prompts outrank user messages. Tool outputs should inform but never command. The tags are the foundation of LLM security architecture.

They are also a fiction.

The model does not see tags the way a parser sees HTML. It sees one continuous stream of tokens. And it decides who is speaking based on stylistic cues. Syntax. Lexical choice. Tone. Even plain-text declarations like "The following is from the user." When these spoofable cues conflict with the actual tags, the cues win.

This is the core finding. The intended defense, tag-enforced role boundaries, does not survive into the model's internal representations.

The CoT Forgery Test

To prove this, the authors designed a diagnostic attack called CoT Forgery. The idea is simple and brutal. Inject fabricated reasoning into a low-privilege channel, a user message or a tool output. Make it sound like the model's own chain of thought. If the model treats it as its own reasoning, it will execute the conclusion without scrutiny.

It works.

Across six frontier models with near-perfect scores on standard safety benchmarks, CoT Forgery achieved 60% attack success on StrongREJECT. The baseline for raw harmful prompts and standard jailbreaks was near zero. GPT-5 models, which have dedicated safety mechanisms, still fell at rates of 17% to 52%. The gpt-oss family and o4-mini collapsed entirely, exceeding 80% attack success.

The attack is fully automated and zero-shot. No weight access. No iteration. An auxiliary LLM generates forged reasoning that mimics the target's CoT style. The payload is just the harmful query plus the forged reasoning, submitted once.

The forged reasoning can be transparently absurd. One example in the paper justifies drug synthesis with the condition that "the user is wearing a green shirt." Absurd justifications achieved 60% attack success. Plausible justifications achieved 63%. The model does not scrutinize. It executes.

Style Is Causal

To isolate the mechanism, the authors ran a style ablation. They took the same forged reasoning, preserved the semantic argument, and stripped out the syntactic and lexical markers that make it sound like chain-of-thought. The result was devastating. Attack success collapsed from 61% to 10%.

Style drives role perception. Not tags. Style.

This is the heart of role confusion. The model has a designed role, chain-of-thought, that exists to be trusted. But the model identifies that role by how the text sounds, not by the <reasoning> tags around it. When untrusted text sounds like reasoning, it inherits the trust reserved for reasoning. Sounding like a role becomes indistinguishable from being that role.

Inside the Model: Role Probes

The authors did not stop at behavior. They built role probes, linear classifiers trained to measure how models internally perceive "who is speaking."

The probe construction is clever. They take identical non-instruct text from pretraining corpora and wrap it in different role tags. The content is held constant. The probe must learn the tag's geometric signature in the model's hidden states. By design, the probe can only detect tags.

Yet when deployed on prompt-injected text, the probes classify it as the spoofed role, not the true tagged role. A text wrapped in <tool> tags but written in a user's command style gets classified as user text. A text wrapped in <user> tags but written in reasoning style gets classified as CoT. The probes, trained only on tags, activate on style.

This proves the confound is structural. In latent space, style and tags map to convergent features. When they conflict, style dominates.

The authors define CoTness as the probability the model represents a token as its own reasoning. They define Userness, Assistantness, and Toolness the same way. These metrics let them measure role confusion before the model generates a single token.

Predicting Attacks Before They Happen

Here is where the paper gets genuinely unsettling. Role confusion does not just explain attacks. It predicts them.

Across 1,000 agent exfiltration attempts, attack success rose near-monotonically with probe-measured confusion. In the lowest confusion quantile, success was 2%. In the highest quantile, it was 70%. The model's internal state, measured before generation, foretold whether the attack would work.

This means prompt injection is not a post-hoc behavior that emerges during generation. It is a pre-existing representational failure. The model is already confused before it writes its first output token.

Why Current Defenses Fail

The paper draws a sharp distinction between two possible defense mechanisms.

Role perception means the model identifies the true source of text and ignores commands from low-privilege channels regardless of phrasing. This generalizes to novel attacks.

Attack memorization means the model recognizes known attack patterns and refuses them. This is brittle. Change the wording, and the defense evaporates.

Current defenses rely on memorization. State-of-the-art models report near-perfect scores on injection benchmarks. Human red-teamers still achieve success rates approaching 100%. The models detect injections via shallow cues like word matching. They patch known patterns. They do not fix the underlying perception failure.

This is why prompt injection has remained a perpetual whack-a-mole problem. Every patch treats the symptom. The disease is in the model's fundamental representation of role.

What This Means for Defenses

If the root cause is representational, the fix must be representational too. Surface-level patches will not solve it.

The authors do not propose a silver bullet. But their framework changes what effective defense looks like. A defense that works must ensure that internal role representations align with tag-specified sources. It must make style and tags converge in the model's latent space, or it must make tags dominate when they conflict.

This is hard. It may require architectural changes. It certainly requires moving beyond the assumption that tags are enough.

The paper also reframes the threat model. Attackers do not need to find clever new exploits. They only need to make text sound like a high-privilege role. The attack surface is not a set of known patterns. It is the model's entire stylistic vocabulary.

The Bottom Line

Prompt injection has persisted because we have been treating it as a bug to patch. The MIT paper shows it is a design flaw in how models represent authority.

Models do not robustly track who is speaking. They track how the text sounds. When sound and source conflict, sound wins. This is not a failure of safety training. It is a failure of role representation. And it will not be fixed with more benchmarks, more red-teaming, or more refusal tuning.

The path forward requires fixing how models internally perceive role. Until then, every tag-based boundary is a tag-based illusion.


Citations

Suggested Title

Prompt Injection Is Not a Bug. It Is a Design Flaw.

(Alternative: Why Your LLM Cannot Tell Who Is Speaking)

Word Count

~1,350 words (body text only)

Fact-Check Notes

  • The 60% ASR figure is for CoT Forgery on StrongREJECT across frontier models. Verify against paper Figure 2.
  • The 61% to 10% style ablation result is from the paper's Figure 4. Verify exact numbers.
  • The 2% to 70% quantile result is from 1,000 agent exfiltration attempts. Verify against paper Section 5.
  • gpt-oss-20b and gpt-oss-120b are real models referenced in the paper. GPT-5 family (nano, mini, full) and o4-mini are also referenced.
  • The paper authors are Charles Ye, Jasmine Cui, and Dylan Hadfield-Menell (MIT).