← Lab /Security & privacy

Decoupling localization from authorization lets small LLMs achieve 0.32% attack success

Separating instruction localization from authorization enables lightweight LLMs to maintain strong IPI defense

Security & privacy arXiv 19 Oct 2026 Method Prototype evidence

Published as “SpanGuard: Decoupling Instruction Localization from Authorization for Lightweight IPI Defense”

Why it matters

Organizations can protect LLM agents from indirect prompt injection using much smaller, cheaper models without sacrificing security.

Summary

SpanGuard reduces indirect prompt injection attack success to 0.32% with a 7B guardrail model while keeping benign utility high, and it works across a range of smaller and diverse LLMs. The approach separates instruction localization (via unsupervised semantic segmentation) from authorization (via a small LLM), which lowers the required model capability. Evidence comes from extensive benchmarks on AgentDojo, comparisons to 13 baselines, and adaptive attack evaluations, though latency is higher than some single-inference defenses.

What they found 2

  1. SpanGuard achieves the lowest overall attack success rate among all evaluated defenses, reaching 0.32% with GPT-4.1-mini and 0.00% with Llama-3.3-70B.

    “Using only a 7B-scale guardrail model, SpanGuard achieves the lowest overall ASR among all evaluated defenses, reaching 0.32% with GPT-4.1-mini and 0.00% with Llama-3.3-70B.”

  2. The defense maintains low ASR across six different LLM families at comparable scales.

    “SpanGuard maintains consistently low ASR and comparable BU and UA across six LLM families at comparable model scales, indicating that its defense effectiveness is not strongly tied to a particular model family.”

Caveats 5

  • For the Qwen2.5-7B guardrail model, SpanGuard’s ASR is 2.10% (Qwen2.5-7B 69.10% 64.90% 2.10%).
  • When using block-level granularity, SpanGuard’s ASR is 2.06% (Block (Ours) ... ASR 2.06%).
  • SpanGuard incurs higher latency than several LLM-based defenses, e.g., 3.89 s compared to <0.01 s for Spotlighting.
  • SpanGuard incurs higher latency than several LLM-based defenses that process the entire tool output in a single inference, because it separately evaluates multiple localized blocks.
  • This additional inference cost is inherent to our decoupled design.

What’s new here 4

  • Decouples instruction localization from authorization, allowing a small LLM to perform the security check.
  • Uses lightweight, unsupervised semantic-discontinuity segmentation to isolate potential injection spans.
  • Demonstrates strong defense performance with 7B-scale models and across multiple model families.
  • Shows robustness against adaptive search-based attacks.