AlignSentinel: Alignment-Aware Detection of Prompt Injection Attacks
On the map: LLM safety and security → Prompt injection and agent security
Abstract (arXiv)
Prompt injection attacks insert malicious instructions into an LLM's input to steer it toward an attacker-chosen task instead of the intended one. Existing detection defenses typically classify any input with instruction as malicious, leading to misclassification of benign inputs containing instructions that align with the intended task. In this work, we account for the instruction hierarchy and distinguish among three categories: inputs with misaligned instructions, inputs with aligned instructions, and non-instruction inputs. We introduce AlignSentinel, a three-class classifier that leverages features derived from LLM's attention maps to categorize inputs accordingly. To support evaluation, we construct the first systematic benchmark containing inputs from all three categories. Experiments on both our benchmark and existing ones--where inputs with aligned instructions are largely absent--show that AlignSentinel accurately detects inputs with misaligned instructions and substantially outperforms baselines.
Key facts. Cited by 4 papers in the map (data through 7 Oct 2026). Placed in Prompt injection and agent security, one of 12 directions in LLM safety and security. First posted on arXiv 14 Feb 2026.
Builds on
No reference list yet.
Built on by
Citing papers per year: 2026: 4.
4 papers.
- 2026When Benchmarks Lie: Evaluating Malicious Prompt Classifiers Under True Distribution Shiftcited by 8
- 2026Send a SCOUT First: Pre-hoc Reasoning for Adaptive Detector Allocation in Prompt-Injection Defensecited by 0
- 2026Where Instruction Hierarchy Breaks: Diagnosing and Repairing Failures in Reasoning Language Modelscited by 0
- 2026Beyond the Verdict: Evidence-Aligned Evaluation of Visual Prompt-Injection Guardrailscited by 0
- 2026Beyond the Verdict: Evidence-Aligned Evaluation of Visual Prompt-Injection Guardrails2 Sep 2026
- 2026Where Instruction Hierarchy Breaks: Diagnosing and Repairing Failures in Reasoning Language Models5 Jun 2026
- 2026Send a SCOUT First: Pre-hoc Reasoning for Adaptive Detector Allocation in Prompt-Injection Defense29 May 2026
- 2026When Benchmarks Lie: Evaluating Malicious Prompt Classifiers Under True Distribution Shift15 Feb 2026
Similar, not cited
Close in wording, no citation either way
- 2024Enhancing Prompt Injection Attacks to LLMs via Poisoning Alignment
- 2025Defending against Indirect Prompt Injection by Instruction Detection
- 2025Meta SecAlign: A Secure Foundation LLM Against Prompt Injection Attacks
- 2026RouteGuard: Internal-Signal Detection of Skill Poisoning in LLM Agents
- 2024SecAlign: Defending Against Prompt Injection with Preference Optimization
- 2026Know Thy Enemy: Securing LLMs Against Prompt Injection via Diverse Data Synthesis and Instruction-Level Chain-of-Thought Learning
- 2026LocalAlign: Enabling Generalizable Prompt Injection Defense via Generation of Near-Target Adversarial Examples for Alignment Training
- 2025ARGUS: Defending Against Multimodal Indirect Prompt Injection via Steering Instruction-Following Behavior