NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Jigsaw Puzzles: Splitting Harmful Questions to Jailbreak Large Language Models

Hao Yang, Lizhen Qu, Ehsan Shareghi, Gholamreza Haffari · DOI

Abstract

Large Language Models (LLMs) are increasingly equipped with safety guardrails to prevent the generation of harmful content. However, these defenses often focus on single-turn interactions. This paper introduces Jigsaw Puzzles (JSP), a multi-turn jailbreak strategy that bypasses safety filters by fragmenting harmful queries into seemingly benign components. By instructing the model to reconstruct the full context only at the final step, JSP achieves a staggering 93.76% average attack success rate across top-tier models, including GPT-4 and Gemini-1.5-Pro.

Introduction

While current "red teaming" research primarily targets single-turn attacks, LLMs possess massive context windows and robust reasoning capabilities that remain under-scrutinized in multi-turn scenarios. The authors identify a critical vulnerability: safety mechanisms often struggle to track harmful intent when it is distributed across a conversation. JSP exploits this by presenting a "puzzle" to the model, where individual pieces appear harmless in isolation but form a prohibited request when reassembled in the model's latent space.

Methodology

The JSP method utilizes a two-pronged approach: a specialized system-level prompt and a rigorous three-stage splitting strategy.

The JSP Prompt

The attack begins with a set of "rules" that define the game. The LLM is informed that a question has been divided into fractions and must wait for all pieces before responding. To evade detection, the prompt forbids the model from repeating the concatenated question and mandates a "hypothetical" disclaimer to bypass output-side guardrails.

The 3-Stage Splitting Strategy

To ensure the fragments remain below the threshold of safety filters, the query undergoes three transformations:

  1. Stage 1 (Unifying Structure): Rewriting the query into a consistent format (e.g., "How do I implement for...").
  2. Stage 2 (Sentence-level Splitting): Breaking the query to isolate harmful keywords.
  3. Stage 3 (Word-level Splitting): Further decomposing harmful words into meaningless letter chunks (e.g., "laundering" becomes "laun" and "dering").
The three-stage splitting strategy used in JSP to fragment harmful queries.

Experimental Setup

The study utilized a refined version of the Figstep dataset, consisting of 189 harmful questions across seven categories: Illegal Activities, Hate Speech, Malware Generation, Physical Harm, Fraud, Pornography, and Privacy Violence. The attack was tested against five state-of-the-art models: Gemini-1.5-Pro, Llama-3.1-70B, GPT-4, GPT-4o, and GPT-4o-mini.

Key Results

JSP demonstrated exceptional efficacy across all tested models and categories. The average success rate (ASR-q) was 93.76%, with Llama-3.1-70B and GPT-4 proving most vulnerable, both exceeding a 99% success rate.

Heatmap showing the Attack Success Rate (ASR-a) across different harmful categories and models.

Notably, JSP outperformed established benchmarks like PAPs (88%) and PAIR (54%) on GPT-4. The results indicate that more "helpful" models—those with superior instruction-following and reasoning capabilities—are paradoxically more susceptible to JSP, as they are better at the "latent reassembly" required to solve the puzzle.

Discussion and Conclusion

The success of Jigsaw Puzzles highlights a fundamental flaw in current safety architectures: the reliance on per-turn intent classification. As models become more capable of complex multi-step reasoning, they can effectively "think" forbidden thoughts behind the back of the guardrail if the input is sufficiently fragmented.

Future defense mechanisms must evolve to be memory-aware, evaluating the safety of an entire conversation's reconstructed intent rather than isolated prompts. While multi-turn attacks currently face higher latency and cost barriers, their near-perfect success rate against frontier models necessitates immediate attention from the AI safety community.

Summary updated

BibTeX
@misc{yang2024jigsaw,
  author = {Hao Yang and Lizhen Qu and Ehsan Shareghi and Gholamreza Haffari},
  title = {{Jigsaw Puzzles: Splitting Harmful Questions to Jailbreak Large Language Models}},
  year = {2024},
  eprint = {2410.11459},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2410.11459},
}
Figure