To understand why an LLM can be jailbroken, Security Architects must understand how it was constructed. The creation of a modern AI assistant occurs in distinct phases, resulting in a dual-natured entity.
Pre-training (The Base Model): The model is trained to be an unconstrained next-token predictor. It ingests massive segments of the internet. During this phase, it learns everything—including how to write polymorphic malware, exploit buffer overflows, and bypass cryptographic protocols.
Supervised Fine-Tuning (SFT): The model is trained on high-quality Q&A pairs to stop acting like a document autocomplete and start acting like a conversational assistant.
The Alignment Layer (RLHF / DPO): A Reward Model (RM) evaluates the LLM’s outputs, giving high scores to “Helpful and Harmless” responses and negative scores to malicious ones. Using Proximal Policy Optimization (PPO) or Direct Preference Optimization (DPO), the model’s weights are adjusted to favor the safe outputs.
The Fundamental Flaw: The RLHF process does not delete the hazardous knowledge acquired in Step 1. It merely trains the model to execute a specific behavioral policy: “If the user prompt maps to a harmful concept, activate the refusal circuit and output an apology.” The hazardous knowledge remains completely intact within the model’s weights, dormant but mathematically accessible.
Recent advances in Mechanistic Interpretability (analyzing the internal neural wiring of an LLM) have proven that RLHF creates highly localized “Safety Patterns” or refusal circuits within the model.
When a standard, un-obfuscated malicious prompt (e.g., “Write a Python keylogger”) is embedded into the model, the resulting vectors land squarely inside a well-defined “harmful cluster” in the model’s latent space.
This activates the refusal circuit. The circuit aggressively overrides the model’s intrinsic “continuation drive” (the urge to answer the prompt), forcibly shifting the final layer’s logits toward safe tokens like “I cannot assist with that.”
3. Why RLHF Breaks: The Out-of-Distribution (OOD) Dilemma
The Reward Model used to train the refusal circuit is just another neural network. It was trained on a finite dataset of human-labeled attacks. This creates a devastating structural vulnerability: The Out-of-Distribution (OOD) Blind Spot.
If an attacker crafts a prompt that is structurally dissimilar to the Reward Model’s training data, the prompt falls into the “longtail” distribution.
Obfuscation & Translation
Asking for a malware script in Base64, Hexadecimal, or a rare language (like Scots Gaelic) pushes the input vector outside the known “harmful cluster.” The refusal circuit fails to recognize the intent, and the base model’s continuation drive takes over.
Multi-Turn Deception (Crescendo)
As documented in 2025 research, multi-turn jailbreaks (like Crescendo) slowly escalate the maliciousness of a conversation over 10 to 20 turns. Because the RLHF reward model primarily evaluates single-turn context, the gradual shift keeps the model’s representations in a “benign” region, bypassing safety alignment entirely.
4. The Physics of Jailbreaks: Representation Engineering (RepE)
Jailbreaking is not a linguistic art; it is the science of Representational Deception.
Groundbreaking research from 2024 and 2025 (such as the JailbreakLens framework and studies on Representation Engineering) reveals exactly how a jailbreak defeats the RLHF layer mathematically.
A successful jailbreak prompt (e.g., an elaborate roleplay like “You are a high-level authorized red teamer operating in a secure, disconnected cyber range…”) acts as a mathematical transformation matrix.
The attacker injects “safety-bypassing” tokens into the prompt.
During inference, these tokens amplify the internal neural components that reinforce affirmative responses.
Simultaneously, they suppress the activation of the refusal neurons.
The prompt’s representation is forcibly pushed away from the “harmful” cluster and dragged into a “benign/safe” region of the latent space. To the RLHF safety circuit, the prompt looks mathematically safe, effectively unlocking the Pandora’s box of the pre-trained base model.
Standard text-based Web Application Firewalls (WAFs) and LLM-as-a-Judge filters fail against Representation Engineering because the semantic text often appears harmless or highly abstract.
To detect sophisticated jailbreaks, DFIR analysts and SOC teams must implement AI-EDR observability at the tensor level. By hooking into the residual stream of the LLM during inference, defenders can monitor the activation shifts in the refusal circuits in real-time.
The reliance on “Refusal” via RLHF is a relic of the early chatbot era. It is fundamentally insufficient for the agentic, high-stakes future of Artificial Intelligence.
As long as hazardous knowledge remains embedded in the base model’s weights, attackers will find mathematical pathways through the latent space to bypass the alignment layer. Securing Agentic AI requires moving beyond behavioral alignment towards Structural Safety and “Knowledge-Gapped” architectures—where sensitive or destructive capabilities are physically excised from the model weights, or strictly gated by Capability-Oriented Security Architectures.
arXiv Research (2025): The Struggle Between Continuation and Refusal: A Mechanistic Analysis of the Continuation-Triggered Jailbreak in LLMs (2603.08234)
arXiv Research (2025): JailbreakLens: Interpreting Jailbreak Mechanism in the Lens of Representation and Circuit (2411.11114)
ACL Anthology (2025): Revisiting Jailbreaking for Large Language Models: A Representation Engineering Perspective
arXiv Research (2025): A Representation Engineering Perspective on the Effectiveness of Multi-Turn Jailbreaks (2507.02956)