SecurityLingua: Efficient Defense of LLM Jailbreak Attacks via Security-Aware Prompt Compression
On the map: Efficient LLM inference and serving → Diffusion LLM and MoE inference
also in 1 more
Abstract (arXiv)
Large language models (LLMs) have achieved widespread adoption across numerous applications. However, many LLMs are vulnerable to malicious attacks even after safety alignment. These attacks typically bypass LLMs' safety guardrails by wrapping the original malicious instructions inside adversarial jailbreaks prompts. Previous research has proposed methods such as adversarial training and prompt rephrasing to mitigate these safety vulnerabilities, but these methods often reduce the utility of LLMs or lead to significant computational overhead and online latency. In this paper, we propose SecurityLingua, an effective and efficient approach to defend LLMs against jailbreak attacks via security-oriented prompt compression. Specifically, we train a prompt compressor designed to discern the "true intention" of the input prompt, with a particular focus on detecting the malicious intentions of adversarial prompts. Then, in addition to the original prompt, the intention is passed via the system prompt to the target LLM to help it identify the true intention of the request. SecurityLingua ensures a consistent user experience by leaving the original input prompt intact while revealing the user's potentially malicious intention and stimulating the built-in safety guardrails of the LLM. Moreover, thanks to prompt compression, SecurityLingua incurs only a negligible overhead and extra token cost compared to all existing defense methods, making it an especially practical solution for LLM defense. Experimental results demonstrate that SecurityLingua can effectively defend against malicious attacks and maintain utility of the LLM with negligible compute and latency overhead. Our code is available at https://aka.ms/SecurityLingua.
Key facts. Cited by 13 papers in the map (data through 14 Oct 2026). Placed in Diffusion LLM and MoE inference, one of 12 directions in Efficient LLM inference and serving. Builds on 45 of its 54 references that are in the map. First posted on arXiv 15 Jun 2025.
Builds on
45 of 54 references.
References · 45
- 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 13,028
- 2021Training Verifiers to Solve Math Word Problemscited by 10,109
- 2020Measuring Massive Multitask Language Understandingcited by 7,963
- 2018Think you have Solved Question Answering? Try ARC, the AI2 Reasoning Challengecited by 4,886
- 2019Unsupervised Cross-lingual Representation Learning at Scalecited by 3,935
- 2023GPQA: A Graduate-Level Google-Proof Q&A Benchmarkcited by 2,879
- 2023Jailbroken: How Does LLM Safety Training Fail?cited by 1,651
- 2023Jailbreaking Black Box Large Language Models in Twenty Queriescited by 1,420
- 2023AutoDAN: Generating Stealthy Jailbreak Prompts on Aligned Large Language Modelscited by 785
- 2023Tree of Attacks: Jailbreaking Black-Box LLMs Automaticallycited by 672
- 2023Baseline Defenses for Adversarial Attacks Against Aligned Language Modelscited by 651
- 2024How Johnny Can Persuade LLMs to Jailbreak Them: Rethinking Persuasion to Challenge AI Safety by Humanizing LLMscited by 573
33 more
- 2023GPTFUZZER: Red Teaming Large Language Models with Auto-Generated Jailbreak Promptscited by 560
- 2024JailbreakBench: An Open Robustness Benchmark for Jailbreaking Large Language Modelscited by 536
- 2023"Do Anything Now": Characterizing and Evaluating In-The-Wild Jailbreak Prompts on Large Language Modelscited by 489
- 2024Jailbreaking Leading Safety-Aligned LLMs with Simple Adaptive Attackscited by 486
- 2023SmoothLLM: Defending Large Language Models Against Jailbreaking Attackscited by 469
- 2023LongLLMLingua: Accelerating and Enhancing LLMs in Long Context Scenarios via Prompt Compressioncited by 453
- 2023Detecting Language Model Attacks with Perplexitycited by 431
- 2024LLMLingua-2: Data Distillation for Efficient and Faithful Task-Agnostic Prompt Compressioncited by 348
- 2023Visual Adversarial Examples Jailbreak Aligned Large Language Modelscited by 328
- 2023LLMLingua: Compressing Prompts for Accelerated Inference of Large Language Modelscited by 287
- 2023Certifying LLM Safety against Adversarial Promptingcited by 266
- 2024SafeDecoding: Defending against Jailbreak Attacks via Safety-Aware Decodingcited by 247
- 2023LLM Self Defense: By Self Examination, LLMs Know They Are Being Trickedcited by 244
- 2024JailBreakV: A Benchmark for Assessing the Robustness of MultiModal Large Language Models against Jailbreak Attackscited by 230
- 2024WildTeaming at Scale: From In-the-Wild Jailbreaks to (Adversarially) Safer Language Modelscited by 223
- 2023Scalable and Transferable Black-Box Jailbreaks for Language Models via Persona Modulationcited by 214
- 2024SecAlign: Defending Against Prompt Injection with Preference Optimizationcited by 210
- 2023Defending Against Alignment-Breaking Attacks via Robustly Aligned LLMcited by 192
- 2023Compressing Context to Enhance Inference Efficiency of Large Language Modelscited by 189
- 2025Constitutional Classifiers: Defending against Universal Jailbreaks across Thousands of Hours of Red Teamingcited by 181
- 2024AutoDefense: Multi-Agent LLM Defense against Jailbreak Attackscited by 145
- 2024Attacking Large Language Models with Projected Gradient Descentcited by 94
- 2024Harmful Fine-tuning Attacks and Defenses for Large Language Models: A Surveycited by 90
- 2024Defending Against Unforeseen Failure Modes with Latent Adversarial Trainingcited by 88
- 2024Intention Analysis Makes LLMs A Good Jailbreak Defendercited by 74
- 2024Defending Large Language Models against Jailbreak Attacks via Semantic Smoothingcited by 74
- 2024RigorLLM: Resilient Guardrails for Large Language Models against Undesired Contentcited by 68
- 2023The Art of Defending: A Systematic Evaluation and Analysis of LLM Defense Strategies on Safety and Over-Defensivenesscited by 67
- 2024Semantic Mirror Jailbreak: Genetic Algorithm Based Jailbreak Prompts Against Open-source LLMscited by 53
- 2024Pruning for Protection: Increasing Jailbreak Resistance in Aligned LLMs Without Fine-Tuningcited by 26
- 2024RobustKV: Defending Large Language Models against Jailbreak Attacks via KV Evictioncited by 21
- 2024Attack Atlas: A Practitioner's Perspective on Challenges and Pitfalls in Red Teaming GenAIcited by 16
- 2024Self-Evaluation as a Defense Against Adversarial Attacks on LLMscited by 14
Built on by
Citing papers per year: 2025: 6; 2026: 7.
13 papers.
Sort:
By area:
- 2025Qwen3Guard Technical Reportcited by 155
- 2025Semantic Attacks on Tool-Augmented LLMs: Securing the Model Context Protocol Against Descriptor-Level Manipulationcited by 13
- 2025Rethinking Jailbreak Detection of Large Vision Language Models with Representational Contrastive Scoringcited by 11
- 2025Proactive defense against LLM Jailbreakcited by 7
- 2026CoopGuard: Stateful Cooperative Agents Safeguarding LLMs Against Evolving Multi-Round Attackscited by 2
- 2025Context Misleads LLMs: The Role of Context Filtering in Maintaining Safe Alignment of LLMscited by 1
- 2025When Compression Becomes an Attack Surface: Black-Box Attacks on Prompt-Compressed LLM Agentscited by 0
- 2026Security Assessment and Mitigation Strategies for Large Language Models: A Comprehensive Defensive Frameworkcited by 0
- 2026Dictionary-Aligned Concept Control for Safeguarding Multimodal LLMscited by 0
- 2026Stateful Cooperative Agents Safeguarding LLMs Against Evolving Multi-Turn Attackscited by 0
- 2026RAGOCR: Optical Compression of Retrieval-Augmented Text via Visual Representationcited by 0
- 2026Capability-Routed Guard: Defending Large Reasoning Models Against Reasoning-Centric Jailbreakscited by 0
- 2026Toward Secure AI-Powered Penetration Testing Agents: Security Threats, Guardrails, and Architectural Perspectives15 Sep 2026
- 2026Capability-Routed Guard: Defending Large Reasoning Models Against Reasoning-Centric Jailbreaks8 Aug 2026
- 2026RAGOCR: Optical Compression of Retrieval-Augmented Text via Visual Representation1 Aug 2026
- 2026Stateful Cooperative Agents Safeguarding LLMs Against Evolving Multi-Turn Attacks31 Jul 2026
- 2026Dictionary-Aligned Concept Control for Safeguarding Multimodal LLMs10 Apr 2026
- 2026CoopGuard: Stateful Cooperative Agents Safeguarding LLMs Against Evolving Multi-Round Attacks5 Apr 2026
- 2026Security Assessment and Mitigation Strategies for Large Language Models: A Comprehensive Defensive Framework17 Mar 2026
- 2025Rethinking Jailbreak Detection of Large Vision Language Models with Representational Contrastive Scoring12 Dec 2025
- 2025Semantic Attacks on Tool-Augmented LLMs: Securing the Model Context Protocol Against Descriptor-Level Manipulation6 Dec 2025
- 2025When Compression Becomes an Attack Surface: Black-Box Attacks on Prompt-Compressed LLM Agents27 Oct 2025
- 2025Qwen3Guard Technical Report16 Oct 2025
- 2025Proactive defense against LLM Jailbreak6 Oct 2025
- 2025Semantic Attacks on Tool-Augmented LLMs: Securing the Model Context Protocol Against Descriptor-Level Manipulationcited by 13
- 2026CoopGuard: Stateful Cooperative Agents Safeguarding LLMs Against Evolving Multi-Round Attackscited by 2
- 2025When Compression Becomes an Attack Surface: Black-Box Attacks on Prompt-Compressed LLM Agentscited by 0
- 2026Stateful Cooperative Agents Safeguarding LLMs Against Evolving Multi-Turn Attackscited by 0
- 2026Toward Secure AI-Powered Penetration Testing Agents: Security Threats, Guardrails, and Architectural Perspectivescited by 0
- 2026Toward Secure AI-Powered Penetration Testing Agents: Security Threats, Guardrails, and Architectural Perspectives15 Sep 2026
- 2026Stateful Cooperative Agents Safeguarding LLMs Against Evolving Multi-Turn Attacks31 Jul 2026
- 2026CoopGuard: Stateful Cooperative Agents Safeguarding LLMs Against Evolving Multi-Round Attacks5 Apr 2026
- 2025Semantic Attacks on Tool-Augmented LLMs: Securing the Model Context Protocol Against Descriptor-Level Manipulation6 Dec 2025
- 2025When Compression Becomes an Attack Surface: Black-Box Attacks on Prompt-Compressed LLM Agents27 Oct 2025
Similar, not cited
Close in wording, no citation either way
- 2023A Wolf in Sheep's Clothing: Generalized Nested Jailbreak Prompts can Fool Large Language Models Easily
- 2024Defensive Prompt Patch: A Robust and Interpretable Defense of LLMs against Jailbreak Attacks
- 2024SelfDefend: LLMs Can Defend Themselves against Jailbreaking in a Practical Manner
- 2024Defending Large Language Models Against Jailbreak Attacks via Layer-specific Editing
- 2024Jailbreak Attacks and Defenses Against Large Language Models: A Survey
- 2025Jailbreaking with Universal Multi-Prompts
- 2026Re-Triggering Safeguards within LLMs for Jailbreak Detection
- 2025Scalable Defense against In-the-wild Jailbreaking Attacks with Safety Context Retrieval