Red-TTT: Test-Time Training for Automated Jailbreaking Large Language Models
cs.CL, cs.CR
Submitted: 2026-10-04
Updated: 2026-10-04
Comments: 29 pages
Code: https://github.com/SaFo-Lab/Red-TTT
License: http://creativecommons.org/licenses/by-sa/4.0/
The gist: Large language models remain vulnerable to jailbreaks, and automated red teaming is the standard way to find jailbreaks in large language models at scale.
Abstract
Large language models remain vulnerable to jailbreaks, and automated red teaming is the standard way to find jailbreaks in large language models at scale. Current methods either draw more samples at test time through search, rewriting, and tree expansion, or train a stronger attacker offline with reinforcement learning. Both share a limitation: once an attack on a specific target behavior begins, the attacker's weights are frozen. Any signal it gathers about the behavior stays in its context window and is discarded afterward. The attacker never adapts its proposal distribution mid-attack, so success depends almost entirely on the sampling budget, and under a budget affordable at scale, many behaviors remain unbroken. We propose Red-TTT, which updates the attacker's parameters during the attack on each behavior. At each round, the attacker samples a group of candidates, scores them against the victim's replies, and takes a policy-gradient step before drawing the next group, so what it discovers about the current victim is consolidated into weights rather than accumulated as context. We also adapt the training objective to red teaming, where success is judged by the single best sample rather than the average. Red-TTT requires only sampling access to the victim and integrates into existing attack pipelines with no other changes. Against the Best-of-N baseline, Red-TTT raises attack success rate from 55.9% to 72.4% on average at a budget of 120 samples, improving over the baseline in every configuration and cracking many behaviors previous method cannot. The code is available at https://github.com/SaFo-Lab/Red-TTT
Sources
- The Surprising Effectiveness of Test-Time Training for Few-Shot Learning
- Jailbreaking Black Box Large Language Models in Twenty Queries
- DeepSeek-V4: Towards Highly Efficient Million-Token Context Intelligence
- The Llama 3 Herd of Models
- Jailbreak-R1: Exploring the Jailbreak Capabilities of LLMs via Reinforcement Learning
- Best-of-N Jailbreaking
- Llama Guard: LLM-based Input-Output Safeguard for Human-AI Conversations
- ArtPrompt: ASCII Art-based Jailbreak Attacks against Aligned LLMs
- DeepInception: Hypnotize Large Language Model to Be Jailbreaker
- CodeChameleon: Personalized Encryption Framework for Jailbreaking Large Language Models
- HarmBench: A Standardized Evaluation Framework for Automated Red Teaming and Robust Refusal
- Tree of Attacks: Jailbreaking Black-Box LLMs Automatically
- GPT-4 Technical Report
- gpt-oss-120b & gpt-oss-20b Model Card
- Qwen2.5 Technical Report
- DeepSeekMath: Pushing the Limits of Mathematical Reasoning in Open Language Models
- A StrongREJECT for Empty Jailbreaks
- HarmMetric Eval: Benchmarking Metrics and Judges for LLM Harmfulness Assessment
- PISmith: Reinforcement Learning-based Red Teaming for Prompt Injection Defenses
- GPTFUZZER: Red Teaming Large Language Models with Auto-Generated Jailbreak Prompts
Related papers
- Exploring Solution Divergence and Its Effect on Large Language Model Problem Solving
- Ishigaki-IDS-Bench: A Benchmark for Generating Information Delivery Specification from BIM Information Requirements
- Subliminal Steering: Stronger Encoding of Hidden Signals
- MedStruct-S: A Benchmark for Key Discovery, Key-Conditioned QA and Semi-Structured Extraction from OCR Clinical Reports
- The End of Transformers? On Challenging Attention and the Rise of Sub-Quadratic Architectures
- Untangling the Mechanisms of Misleading Context in Medical Question Answering