Observatory research catalog · ATO.T24040001 · High severity

LLM Jailbreak: Many-shot jailbreaking (research family)

Many-shot jailbreaking exploits long context windows (100k+ tokens) by stuffing dozens to hundreds of synthetic compliant dialogue turns ahead of a restricted request (Anthropic, 2024). As shot count increases, standard in-context learning dynamics override post-training safety refusals across text and multimodal models.

Technique dossier overview

Category
Prompt and context integrity
Severity
High
Attack surface
LLM / Prompt Layer · Inference API & Hosting
Platforms
Generative AI
Tactics
Defense Evasion, Privilege Escalation
Aliases
Long-context safety robustness, Many-shot
Catalog entry modified
Earliest cited research
· Many-shot jailbreaking · Anthropic

Open ATO.T24040001 in Interactive Technique Workbench

How the mechanism works

  1. An adversary constructs a single oversized prompt containing a long sequence of simulated Q&A turns demonstrating compliant answers to sensitive or policy-violating topics.
  2. A final target query is appended at the end of the synthetic dialogue inside the extended context window.
  3. Because transformer attention follows the strong in-context pattern established across hundreds of preceding demonstrations, safety refusal weights weaken smoothly with context length.

Detection & telemetry signals

Architectural defensive countermeasures

Framework crosswalk (OWASP LLM Top 10 & NIST AI RMF)

OWASP LLM Top 10 (2025)
OWASP rationale
Long-context demonstration stuffing executes Prompt Injection/alignment override (LLM01) while driving high per-request token consumption (LLM10).
NIST AI RMF functions
NIST AI RMF guidance
Benchmark refusal robustness as a function of context window size under MEASURE, and enforce full-window classifiers, role-tag sanitization, and token budgets under MANAGE.

Mapped defensive controls

Test with Refract

Refract is Silvauren's Apache-2.0 defensive LLM evaluation harness. Its 2x2 Detect-vs-Complete matrix crosses whether a detector flagged each probe with whether the model complied, so silent breaches are counted with Wilson 95% confidence intervals. Replace <model-id> with an OpenRouter route ID; each model page lists a ready-to-run command for its own route.

refract scan \
  --target "openai_compat:<model-id>" \
  --base-url https://openrouter.ai/api/v1 \
  --api-key "$OPENROUTER_API_KEY" \
  --battery many_shot
refract report

Export OPENROUTER_API_KEY first. Passing --api-key keeps Refract from using an unrelated OPENAI_API_KEY, which it would otherwise read first. Scans send real requests billed to your key. Add --max-probes or --budget-tokens to cap spend, and only scan endpoints you are authorized to test.

Published empirical measurements (2)

Related technique records

Documented incidents & exercises (1)

Source citation records

Common questions

What is LLM Jailbreak: Many-shot jailbreaking (research family) (ATO.T24040001)?
Many-shot jailbreaking exploits long context windows (100k+ tokens) by stuffing dozens to hundreds of synthetic compliant dialogue turns ahead of a restricted request (Anthropic, 2024). As shot count increases, standard in-context learning dynamics override post-training safety refusals across text and multimodal models.
How do you mitigate LLM Jailbreak: Many-shot jailbreaking (research family)?
MITRE ATLAS maps 5 mitigations to ATO.T24040001: Validate AI Model, Generative AI Guardrails, Generative AI Model Alignment, AI Telemetry Logging and Monitoring, and Limit AI Workload Resource Consumption. Deploy sliding-window and full-context input classifiers (such as Constitutional Classifiers) trained specifically on long-context multi-demonstration attack patterns rather than short-prefix guards alone.
How can I test a model for LLM Jailbreak: Many-shot jailbreaking (research family)?
Run the Refract many_shot pack: refract scan --target "openai_compat:<model-id>" --base-url https://openrouter.ai/api/v1 --api-key "$OPENROUTER_API_KEY" --battery many_shot, then refract report. Scans send real requests billed to your key. Add --max-probes or --budget-tokens to cap spend, and only scan endpoints you are authorized to test.