STShield: Single-Token Sentinel for Real-Time Jailbreak Detection in Large Language Models
On the map: LLM safety and security → Jailbreaking
Abstract (arXiv)
Large Language Models (LLMs) have become increasingly vulnerable to jailbreak attacks that circumvent their safety mechanisms. While existing defense methods either suffer from adaptive attacks or require computationally expensive auxiliary models, we present STShield, a lightweight framework for real-time jailbroken judgement. STShield introduces a novel single-token sentinel mechanism that appends a binary safety indicator to the model's response sequence, leveraging the LLM's own alignment capabilities for detection. Our framework combines supervised fine-tuning on normal prompts with adversarial training using embedding-space perturbations, achieving robust detection while preserving model utility. Extensive experiments demonstrate that STShield successfully defends against various jailbreak attacks, while maintaining the model's performance on legitimate queries. Compared to existing approaches, STShield achieves superior defense performance with minimal computational overhead, making it a practical solution for real-world LLM deployment.
Key facts. Cited by 3 papers in the map (data through 14 Oct 2026). Placed in Jailbreaking, one of 12 directions in LLM safety and security. Builds on 37 of its 53 references that are in the map. First posted on arXiv 23 Mar 2025.
Builds on
37 of 53 references.
Closest ancestors · 28
Same direction, newest first
- 2024HSF: Defending against Jailbreak Attacks with Hidden State Filtering31 Aug
- 2024Bag of Tricks: Benchmarking of Jailbreak Attacks on LLMs13 Jun
- 2024SelfDefend: LLMs Can Defend Themselves against Jailbreaking in a Practical Manner8 Jun
- 2024Adversarial Tuning: Defending Against Jailbreak Attacks for LLMs7 Jun
- 2024Defensive Prompt Patch: A Robust and Interpretable Defense of LLMs against Jailbreak Attacks30 May
- 2024Defending Large Language Models Against Jailbreak Attacks via Layer-specific Editing28 May
- 2024Efficient Adversarial Training in LLMs with Continuous Attacks24 May
- 2024AmpleGCG: Learning a Universal and Transferable Generative Model of Adversarial Suffixes for Jailbreaking Both Open and Closed LLMs11 Apr
- 2024Eraser: Jailbreaking Defense in Large Language Models via Unlearning Harmful Knowledge8 Apr
- 2024Jailbreaking Leading Safety-Aligned LLMs with Simple Adaptive Attacks2 Apr
- 2024Gradient Cuff: Detecting Jailbreak Attacks on Large Language Models by Exploring Refusal Loss Landscapes1 Mar
- 2024Defending Large Language Models against Jailbreak Attacks via Semantic Smoothing25 Feb
16 more
- 2024Play Guessing Game with LLM: Indirect Jailbreak Attack with Implicit Clues14 Feb
- 2024Fight Back Against Jailbreaking via Prompt Adversarial Tuning9 Feb
- 2024JailbreakRadar: Comprehensive Assessment of Jailbreak Attacks Against LLMs8 Feb
- 2024Robust Prompt Optimization for Defending Language Models Against Jailbreaking Attacks30 Jan
- 2023Tree of Attacks: Jailbreaking Black-Box LLMs Automatically4 Dec
- 2023Defending Large Language Models Against Jailbreaking Attacks Through Goal Prioritization15 Nov
- 2023Jailbreaking Black Box Large Language Models in Twenty Queries12 Oct
- 2023Jailbreak and Guard Aligned Language Models with Only Few In-Context Demonstrations10 Oct
- 2023SmoothLLM: Defending Large Language Models Against Jailbreaking Attacks5 Oct
- 2023Low-Resource Languages Jailbreak GPT-43 Oct
- 2023Defending Against Alignment-Breaking Attacks via Robustly Aligned LLM18 Sep
- 2023Certifying LLM Safety against Adversarial Prompting6 Sep
- 2023Detecting Language Model Attacks with Perplexity27 Aug
- 2023GPT-4 Is Too Smart To Be Safe: Stealthy Chat with LLMs via Cipher12 Aug
- 2023Jailbroken: How Does LLM Safety Training Fail?5 Jul
- 2023Jailbreaking ChatGPT via Prompt Engineering: An Empirical Study23 May
Other references · 9
- 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 13,028
- 2023Judging LLM-as-a-Judge with MT-Bench and Chatbot Arenacited by 8,626
- 2017Towards Deep Learning Models Resistant to Adversarial Attackscited by 6,415
- 2023Llama Guard: LLM-based Input-Output Safeguard for Human-AI Conversationscited by 1,207
- 2022Red Teaming Language Models with Language Modelscited by 1,026
- 2023Enhancing Chat Language Models by Scaling High-quality Instructional Conversationscited by 839
- 2023Baseline Defenses for Adversarial Attacks Against Aligned Language Modelscited by 651
- 2023LLM Self Defense: By Self Examination, LLMs Know They Are Being Trickedcited by 244
- 2024The Language Barrier: Dissecting Safety Challenges of LLMs in Multilingual Contextscited by 94
Built on by
Citing papers per year: 2025: 3.
3 papers.
Similar, not cited
Close in wording, no citation either way
- 2025Test-Time Immunization: A Universal Defense Framework Against Jailbreaks for (Multimodal) Large Language Models
- 2024Prefix Guidance: A Steering Wheel for Large Language Models to Defend Against Jailbreak Attacks
- 2025Single-pass Detection of Jailbreaking Input in Large Language Models
- 2025JBShield: Defending Large Language Models from Jailbreak Attacks through Activated Concept Analysis and Manipulation
- 2026Causal Front-Door Adjustment for Robust Jailbreak Attacks on LLMs
- 2024Rapid Response: Mitigating LLM Jailbreaks with a Few Examples
- 2026SelfGrader: LLM Jailbreak Detection via Anchored Token-Level Logits
- 2026Sparse Autoencoders are Capable LLM Jailbreak Mitigators