Fair-ASR: Re-evaluating black-box jailbreak attacks under a shared target-call budgetFair ASR: Re-Evaluating Black-Box Jailbreaks under Shared Target-Call Budgets
Fair-ASR re-evaluates 11 black-box jailbreaks with a shared target-call budget, and rankings change with budget; ReCode achieves 85% ASR on GPT-5 at B=20 with an average of 7.19 attacker calls.
- Jailbreak evaluations mostly report only ASR, and different budgets make methods incomparable; converting costs to FLOPs is hard for closed-source black-box models and obscures target calls as the constrained resource.
- Fair-ASR compares black-box jailbreaks under a shared target-call budget B, reporting ASR@B, ASR–budget curves, and average target calls, with attacker calls counted separately. Based on this, it proposes ReCode: a single sanitizing rewrite, plus random perturbation and code-style nesting that require no attacker calls.
- The authors state that rankings change with B: on Llama-3.1-8B, TAP is higher than BoN at B=5, and the order reverses at B=100. ReNeLLM averages ASR@100 of 98.7% but with high attacker calls. At B=20, ReCode achieves ASR 85% and AAC 7.19 on GPT-5.
- The authors state that target calls do not count tokens, API prices, and template labor costs, and multi-turn is not yet covered. Experiments cover HarmBench and JailbreakBench, 11 attacks with B=100 and ReCode with B=20.
- Threat model
- Black-box jailbreak: the attacker accesses the target model only through inputs and outputs, without using parameters, gradients, or internal states. The primary budget is the shared target-call count B; attacker calls are counted separately. Evaluation stops at first success or when B is exhausted.
- Evaluated models
- Llama-3.1-8B-InstructLlama-3.1-70B-Instructgpt-oss-20bgpt-oss-120bGPT-4o (gpt-4o-2024-08-06)GPT-5 (gpt-5-2025-08-07)Gemini-3.1-ProClaude-Sonnet-4.6
- Benchmarks
- HarmBenchJailbreakBench
- Metrics
- ASR@BATCHS@BAAC
The paper proposes the Fair-ASR evaluation protocol, using the directly observable target-call count B as a unified comparison axis for black-box jailbreak attacks, and separately recording attacker-side calls for efficiency analysis, replacing the FLOPs metric that is hard to estimate on black-box models. Under Fair-ASR, the authors re-evaluate 11 representative attacks and find that attack rankings change noticeably with the target-call budget; simple random perturbations and handcrafted templates remain competitive under equal target access, and no evaluated LLM-driven method is efficient in both target calls and attacker calls. Based on this efficiency gap, the authors propose the composite attack ReCode, combining desensitizing rewriting with two low-cost primitives identified by Fair-ASR, achieving 85% attack success rate on GPT-5 under a 20 target-call budget, with an average of only 7.19 attacker calls per request.
Paper analysis
What problem does this paper attempt to solve?
Fairly compare black-box jailbreaks under a shared target-call budget, and based on this build an attack that saves calls on both sides.
How to fairly compare black-box jailbreaks under a shared target-call budget, and narrow the efficiency gap on both the target-call and attacker-call sides.
- Scenario and importance: The authors argue that LLMs are widely deployed and face increasing jailbreaks, and comparing which attack is more effective is a core question in safety evaluation. Most work reports only ASR, ignoring the budget used to obtain that ASR; the authors state that ASR is highly sensitive to the evaluation setup, especially the attack budget (D’Angelo, 2025; Xu et al., 2026).
- Shortcomings of existing practices: Endpoint ASR under unequal budgets conflates attack effectiveness with target access volume; Figure 1(a) illustrates that rankings may reverse under the same budget. Converting target, attacker, judge, and gradient costs into a single FLOPs measure (Ehghaghi et al., 2026; Wang et al., 2026a) can quantify total computation, but resources are not interchangeable, equal FLOPs can correspond to very different target exposure, and inference FLOPs for closed-source targets are often unavailable.
- Core observation: Target calls are the common axis across all black-box jailbreaks, directly countable, and constrained by quotas, rate limits, and abuse detection. Simple random perturbations and handcrafted templates remain competitive under equal target access; the authors state that none of the evaluated LLM-driven methods is efficient on both the target-call and attacker-call sides.
- This paper proposes: Fair-ASR, re-evaluating 11 black-box jailbreaks under a shared target-call budget B, and separately tracking attacker calls. Based on this, it proposes the combined attack ReCode: a single sanitizing rewrite, plus random perturbation and structured code-style nesting without attacker calls.
- Threat model:
- Target: To induce the target model to give a response satisfying the harmful intent for a harmful request; success is judged as 1 by the judge G(x_i, y).
- Knowledge: black-box, accessed only through inputs and outputs, without requiring parameters, gradients, or internal state.
- Capability: At most B target calls per request; historical responses can be used to construct subsequent prompts; calls to the attacker model and auxiliary judge do not count toward B.
- Victim system: Aligned LLMs on open-weight and closed-source APIs; one independent generation counts as one target call, including each response in batch returns.
What related research exists?
Related work is divided into three families of black-box jailbreaks, plus benchmarks, budget scaling, and FLOPs accounting.
The paper divides related work into black-box attack families, and two lines of evaluation, scaling, and budget accounting.
Black-box jailbreak attacks
- Handcrafted templates: CodeAttack (Ren et al., 2024), CipherChat (Yuan et al., 2024), DeepInception (Li et al., 2023) use fixed transformations or scenarios.
- Random sampling: BoN (Hughes et al., 2026) repeatedly samples prompt variants, with effectiveness increasing with the number of attempts.
- LLM-driven search: PAIR (Chao et al., 2025), TAP (Mehrotra et al., 2024), ReNeLLM (Ding et al., 2024), AutoDAN-Turbo (Liu et al., 2025), Rainbow Teaming (Samvelyan et al., 2024) use an attacker model to search, consuming both target and attacker calls. Wen et al. (2026) also reuse evolving attack skills across requests. The authors state that these methods are typically evaluated under their own budgets, search, and auxiliary call settings, making reported ASRs difficult to compare across papers.
Evaluation, scaling, and budget accounting
- Standardized benchmarks: JailbreakBench, HarmBench, Jailbreak Foundry (Chao et al., 2024; Mazeika et al., 2024; Fang et al., 2026) improve reproducibility. Xu et al. (2026)'s SoK argues that ASR alone is insufficient and proposes additional evaluation dimensions. The authors state that unified datasets and judges do not equalize attack resources (D’Angelo, 2025; Zhang et al., 2026).
- Budget scaling: BoN shows that increasing sampled variants improves ASR; SABER models this scaling with Best-of-N risk estimation (Hughes et al., 2026; Feng et al., 2026).
- FLOPs accounting: Wang et al. (2026a) and Ehghaghi et al. (2026) combine attacker, target, and judge inference costs into unified FLOPs. The authors state that this conflates resources with different operational constraints, and precise inference FLOPs for closed-source targets are often unavailable; existing budget analyses are either limited to one paradigm or computation-centric.
Baseline methods include DeepInception, CipherChat, CodeAttack, BoN, PAIR, TAP, ReNeLLM, AutoDAN (Liu et al., 2024), GPTFuzzer (Yu et al., 2023), AutoDAN-Turbo, Rainbow Teaming. Benchmarks are HarmBench's 200 standard text behaviors and JailbreakBench's 100 harmful requests.
The authors position this paper as: comparing multiple black-box jailbreaks under a shared target-call budget, rather than being paradigm-specific or accounting only by FLOPs.
How does the paper address this problem?
Use target calls as the primary budget to define metrics such as ASR@B, then construct ReCode from a single rewrite plus two low-cost transformations.
Fair-ASR uses the number of target calls as a comparable primary budget and records attacker calls separately; ReCode uses one sanitizing rewrite followed by two transformations that do not call the attacker model, making each attempt exactly one attacker call plus one target call.
Problem setup and formalization
- Primary budget: Dataset D contains n harmful requests. Each gets at most B target calls. On the b-th call, an adversarial prompt p_{i,b} is constructed, and target T generates y_{i,b}=T(p_{i,b}). Independent generations each count once, including multiple responses within the same batched request.
- Success and early stopping: Judge G(x_i, y) returns 0 or 1. s_i(B) is the maximum of the judgments across calls within the budget. Stop at the first success; otherwise use all B calls.
- Why target calls: They are required by manual templates, random resampling, and LLM-driven attacks alike; target access is constrained by quotas, rate limits, and abuse detection; in closed-source settings they can be counted directly, whereas FLOPs often can only be estimated indirectly. Attacker calls are an auxiliary resource and are not collapsed into a single scalar.
Metrics
- ASR@B: The proportion of requests that succeed within the budget. Computing it for each b gives the ASR–budget curve. Manual templates have K fixed templates, each evaluated once at temperature 0; when B≥K, ASR saturates at K, so ASR@K is reported and ATC is not.
- ATC_B: On success, record the call index of the first success; on failure, record B; then average over requests. The authors state that lower means earlier success under that budget.
- HS@B: Uses the StrongREJECT scale, obtained from GPT-4o as r_i(B)∈[0,1], covering refusal, specificity, and persuasiveness. On success, take the first successful response; otherwise take the response from the last query; then average over requests.
ReCode
- Difference from ReNeLLM: The authors state that ReNeLLM uses a harmfulness-only gate on the prompt, rewriting if it fails, and may call an additional judge, producing multiple attacker calls before a single target query. ReCode removes this retry loop and does a single rewrite directly.
- Three-step combination: 1. Randomly draw one sanitizing strategy and rewrite, counting 1 attacker call; 2. character-level random perturbation, counting no attacker calls; 3. embed a structured code-style nesting, counting no attacker calls, then make 1 target call. Thus, under the same budget, AAC equals ATC. The rewriting strategy names listed in Figure 4 include literary rewrite, benign softening, neutral substitution, and objective substitution; nesting uses 5 manual templates. Appendix C.1 and Appendix E give implementation and prompts, and Appendix D gives a worked example.
- Ablation variants: Remove rewriting and embed the original request directly into the five code-style templates; remove nesting; remove character-level perturbation; restore the ReNeLLM-style gate with rewrite retries.
Implementation and success determination
- Attack configuration: The attacker model for LLM-driven methods in the main experiments is Qwen2.5-7B-Instruct at temperature 0.7. Target models use temperature 0.0. ReNeLLM's prompt filter is Qwen3Guard with max_rewrite_attempts=10. PAIR has max_iterations=100; TAP has root_nodes=3, branching_factor=3, width=10, max_iterations=10. BoN has num_candidates=10, sigma=0.4, min_completion_words=50. Full hyperparameters are in Appendix Tables A.1 and A.2.
- Accounting: Refusals, blocks, failed generations, and warm-up or exploration generations all count as target calls. Attacker models and auxiliary judges are recorded separately. Implementations are adapted from OpenRT and the official TAP and BoN repositories, preserving their respective search and stopping logic.
- Two judges: Fair-ASR re-evaluation uses LlamaGuard4. ReCode experiments use GPT-4o on the X-Teaming scale, with success only at a score of 5, and StrongREJECT for HS. Non-reasoning targets get at most 1,024 output tokens per call; reasoning-capable targets use the highest reasoning effort exposed by the API, up to 3,072 tokens; judges see at most the first 1,024 tokens of the visible response.
What experiments did the paper conduct?
Re-evaluate 11 attacks at B=100, with rankings reversing by budget; ReCode simultaneously reduces calls on both sides at B=20.
Experimental setup
- Target models: Fair-ASR's main evaluation uses Llama-3.1-8B-Instruct, Llama-3.1-70B-Instruct, gpt-oss-20b, gpt-oss-120b, and GPT-4o (gpt-4o-2024-08-06), with B=100. ReCode additionally uses GPT-5 (gpt-5-2025-08-07), Gemini-3.1-Pro, and Claude-Sonnet-4.6, with B=20.
- Attacker models: LLM-driven attacks mainly use Qwen2.5-7B-Instruct; Appendix B.1 switches to Mistral-7B-Instruct-v0.3. Manual templates and BoN have no attacker model.
- Data: HarmBench 200 standard text behaviors; JailbreakBench 100 harmful requests. Averages are unweighted macro averages over the five models.
- Attacks: Manual templates DeepInception (K=8), CipherChat (K=5), CodeAttack (K=8); random-sampling BoN; LLM-driven PAIR, TAP, ReNeLLM, AutoDAN, GPTFuzzer, AutoDAN-Turbo, Rainbow Teaming.
- Metrics and judges: ASR@B, ATC_B, HS@B, and the minimum target calls to reach threshold ρ with the corresponding AAC. Main tables are judged by LlamaGuard4; ReCode's ASR is judged by GPT-4o with success only at a score of 5 on X-Teaming, and HS uses StrongREJECT.
- Generation: Target temperature 0; attacker temperature 0.7. The paper does not report independent repetitions. Appendix B.4 uses request-level bootstrap to assess curve stability.
Main results
Table 1 is on HarmBench with LlamaGuard4; manual templates report ASR@K (no ATC), and the rest report ASR@100 and ATC100.
Swipe horizontally to read the table
Method Llama3.1-8B ASR/ATC Llama3.1-70B gpt-oss-20b gpt-oss-120b GPT-4o Average CodeAttack (8) 95.5 / – 96.0 / – 89.5 / – 83.5 / – 89.0 / – 90.7 / – BoN 96.0 / 27.4 93.0 / 23.0 92.0 / 37.2 71.0 / 60.9 54.5 / 64.2 81.3 / 42.5 TAP 91.5 / 16.2 94.5 / 10.9 58.0 / 61.2 22.5 / 85.7 85.0 / 27.5 70.3 / 40.3 Rainbow Teaming 96.0 / 17.9 98.0 / 16.2 72.5 / 47.0 0.0 / 100.0 63.0 / 63.0 65.9 / 48.8 ReNeLLM 99.0 / 2.5 99.5 / 2.7 99.5 / 3.2 97.0 / 7.1 98.5 / 3.8 98.7 / 3.9 AutoDAN 29.5 / 77.6 37.5 / 68.4 31.0 / 80.3 11.0 / 93.0 29.5 / 82.6 27.7 / 80.4 Not listed in the table are CipherChat (average ASR@K 88.5%), DeepInception (24.1%), GPTFuzzer (43.7% / 62.4), PAIR (60.8% / 47.8), and AutoDAN-Turbo (61.7% / 51.2); all numbers come from Table 1.
- Budget changes rankings: The authors state that in Figure 2(a), on Llama-3.1-8B-Instruct with B=5, TAP is 60.5% and BoN is 43.5%; with B=100, BoN is 96.0% and TAP is 91.5%. ReNeLLM saturates within a few calls, while TAP, PAIR, and AutoDAN-Turbo rise more slowly. Figure 2 also labels CodeAttack's single-template ASR@1: 62% on Llama-3.1-8B and 22% on gpt-oss-120b.
- Simple primitives remain competitive: The authors state that BoN's average endpoint ASR is 81.3% with ATC 42.5 and requires no attacker calls, higher than every LLM-driven attack except ReNeLLM. CodeAttack's average ASR@K is 90.7%. The authors state that AutoDAN-Turbo is markedly worse on gpt-oss and speculate that highly consistent refusal responses may limit its response-dependent policy retrieval.
- Both-side efficiency cannot be had together: The authors state that among the evaluated LLM-driven methods, none is optimal at all thresholds and on both resource dimensions. ReNeLLM has the highest average ASR@100 (98.7%) and lowest ATC (3.9), but its target-call efficiency comes with high rewriting cost.
Multi-resource Pareto
- What was measured: Figure 3, on Llama-3.1-8B-Instruct, JailbreakBench, attacker Qwen2.5-7B-Instruct, judge LlamaGuard4, plots the Pareto frontier of target calls versus average attacker calls for LLM-driven attacks with ρ∈{0.3, 0.6, 0.9} and Bmax=100. Pareto dominance follows Miettinen (1999): no more in either dimension and strictly less in at least one.
- Results: The authors state that within 100 target calls, 6 attacks reach 60% ASR and 3 reach 90%. ReNeLLM typically reaches each threshold with fewer target calls and more attacker calls; PAIR and Rainbow Teaming use more target calls and markedly fewer attacker calls. The frontier changes with ρ. Corresponding values are in Appendix B.3.
- Authors' interpretation: ReNeLLM's target-call efficiency comes from high rewriting cost, because its harmfulness-only gate on the prompt may call the attacker model repeatedly before querying the target (Figure 4).
ReCode and ablations
Table 2 is on JailbreakBench, B=20, attacker Qwen2.5-7B-Instruct, GPT-4o-judged ASR@20 and AAC. "–" means no attacker model.
Swipe horizontally to read the table
Method gpt-oss-20b gpt-oss-120b GPT-5 Gemini-3.1-Pro Claude-Sonnet-4.6 Average ReNeLLM 96 / 10.21 83 / 12.24 31 / 26.02 54 / 18.71 21 / 26.25 57.0 / 18.69 TAP 60 / 47.92 31 / 59.63 50 / 45.03 12 / 46.40 43 / 48.81 39.2 / 49.56 ReCode 96 / 3.02 98 / 3.03 85 / 7.19 80 / 7.51 46 / 14.26 81.0 / 7.00 ReCode w/ Gate 94 / 11.79 95 / 9.24 82 / 18.63 77 / 19.76 40 / 35.64 77.6 / 19.01 - Closed-source transfer: The authors state that rewriting is key for closed-source transfer. Without rewriting, ASR on GPT-5, Gemini-3.1-Pro, and Claude-Sonnet-4.6 is 5%, 12%, and 4%, respectively. On GPT-5, ReCode goes from 31% to 85% relative to ReNeLLM, and AAC from 26.02 to 7.19, with this AAC also being the ATC. Gemini-3.1-Pro goes from 54% to 80%, with AAC and ATC both 7.51.
- Components and gating: The authors state that on GPT-5 and Gemini-3.1-Pro, removing either perturbation or nesting lowers ASR. Claude-Sonnet-4.6 is the opposite: removing nesting raises ASR from 46% to 57%, which the authors attribute to its greater sensitivity to recognizable code-style jailbreak structures. Removing the gate raises average ASR from 77.6% to 81.0% and lowers AAC from 19.01 to 7.00. On GPT-5, the gated variant is 82% with 18.63 calls.
- HS: Table 3 reports HS@20 on the three closed-source models on JailbreakBench. ReCode averages 0.662, corresponding to the authors' stated average ASR@20 of 70.3%. On GPT-5, ReCode's ASR and HS are 85% and 0.781; Gemini-3.1-Pro's HS is 0.743. On Claude-Sonnet-4.6, removing nesting raises both ASR and HS (HS from 0.463 to 0.603). CodeAttack and BoN average HS 0.102 and 0.120 across these three models.
Other ablations and analyses
- Switching attacker (JailbreakBench, Appendix B.1): After switching Qwen to Mistral-7B-Instruct-v0.3, macro-average ASR for each LLM-driven method changes by at most 10.8 percentage points; PAIR goes from 54.4% to 62.6%, AutoDAN-Turbo from 60.6% to 67.0%, and Rainbow Teaming from 77.2% to 66.4%.
- AutoDAN on HarmBench: Average ASR rises from 27.7% to 49.0%; the other six LLM-driven methods change by at most 5.1 percentage points.
- Same Mistral, different dataset: ReNeLLM goes from 99.4% to 99.7%, and CodeAttack stays at 91.2% and 90.7%. Five of the seven change by at most 4.2 percentage points; AutoDAN and GPTFuzzer are 12.2 and 8.0 percentage points higher on HarmBench, respectively.
- JailbreakBench + Qwen (Table B.1): ReNeLLM's average ASR@100 is 99.4% with ATC 4.5; CodeAttack's average ASR@K is 91.2%; Rainbow Teaming on gpt-oss-120b is 47.0% (versus 0.0% on HarmBench in Table 1).
- Low-budget comparison (Table 2): At B=20, CodeAttack averages ASR 43.4% (33% on GPT-5), and BoN averages 18.0% (7% on GPT-5); ReCode w/o Perturbation averages 73.6% / AAC 8.50, and w/o Nesting 65.0% / 10.26.
- Negatives and exceptions: Rainbow Teaming on HarmBench and gpt-oss-120b has ASR@100 0.0 and ATC 100.0. DeepInception on Llama-3.1-70B has ASR@K of only 3.5% (HarmBench) and 4.0% (JailbreakBench). On Claude, removing nesting instead raises ASR and HS.
What are some points that can be further explored?
The authors say target calls do not include token, price, and template costs, and the protocol does not yet cover multi-turn.
Limitations and future directions noted by the authors
- Incomplete cost dimensions: Section 5 states that target calls are observable and broadly applicable, but do not cover token usage, API pricing, or the development cost of manual templates.
- Multi-turn not yet covered: The same section states that Fair-ASR does not yet cover the multi-turn setting.
- Future directions: The authors write that future work will incorporate complementary cost metrics and extend the protocol accordingly.
Experimental coverage
- Re-evaluation scope: 11 black-box attacks, three categories being manual templates, BoN, and LLM-driven; HarmBench 200 items and JailbreakBench 100 items; primary budget B=100, judge LlamaGuard4 (Section 4.1, Table 1, Table B.1).
- Targets and attackers: Main results cover Llama 3.1 8B and 70B, gpt-oss 20b and 120b, and GPT-4o. The attacker for main experiments is Qwen2.5-7B-Instruct; Appendix B.1 switches to Mistral-7B-Instruct-v0.3, with hyperparameters, judge, budget, and stopping criteria unchanged.
- ReCode: B=20, dataset JailbreakBench; targets include gpt-oss-20b/120b from the open-source models above, plus GPT-5, Gemini-3.1-Pro, and Claude-Sonnet-4.6; ASR is judged by GPT-4o with success only at a score of 5 on X-Teaming, and HS uses StrongREJECT (Table 2, Table 3).
- Pareto and curves: Figure 3 reports only the frontier for LLM-driven attacks on Llama-3.1-8B-Instruct with ρ at 0.3/0.6/0.9. Full ASR–budget curves are in Appendix B.2, ReCode curves in Appendix C.2, and Claude sensitivity in Appendix C.3.
- Not reported in the paper: Independent repetitions; full Pareto values for models other than Figure 3 are only pointed to Appendix B.3 in the main text. Request-level bootstrap intervals are in Appendix B.4; the main text gives no interval numbers.
Summarize the main content of the paper
Fair-ASR re-ranks black-box jailbreaks under a shared target-call budget, and ReCode reduces calls on both sides at B=20.
Fair-ASR re-evaluates black-box jailbreaks under a shared target-call budget and, based on this, constructs ReCode, which is more economical on both the target-call and attacker-call sides.
- Problem: Reporting only the endpoint ASR conflates effectiveness with target access; FLOPs are hard to estimate for closed-source targets and collapse resources with different constraints into a single scalar. The authors use target calls as the primary budget, which is directly observable and universal across black-box attack types.
- Protocol: Each harmful request gets at most B target generations, stopping at the first success. Report ASR@B, ASR–budget curves, and ATC; attacker calls are counted separately. HS uses StrongREJECT, scored by GPT-4o. Manual templates report only ASR@K.
- Re-evaluation: On HarmBench, with LlamaGuard4, B=100, ReNeLLM's five-model average ASR@100 is 98.7%, ATC 3.9; CodeAttack's average ASR@K is 90.7%; BoN is 81.3% / ATC 42.5, with no attacker calls. On Llama-3.1-8B with B=5, TAP is 60.5%, higher than BoN's 43.5%; with B=100, BoN is 96.0%, higher than TAP's 91.5%. The authors state that none of the evaluated LLM-driven methods is optimal on both call sides.
- ReCode: One sanitizing rewrite, plus character-level perturbation and one of five code-style nestings, so each attempt's AAC equals its ATC. On JailbreakBench, B=20, judged by GPT-4o, ASR is 85% on GPT-5, AAC 7.19; five-model average 81.0% / 7.00, versus ReNeLLM's 57.0% / 18.69. Average HS@20 across the three closed-source models is 0.662. On Claude-Sonnet-4.6, removing nesting raises ASR from 46% to 57%.
- Authors' conclusion: Rankings depend on the chosen budget, and simple primitives remain competitive under equal target access. Section 5 states that target calls do not cover tokens, API prices, or template labor costs, and the protocol does not yet cover multi-turn; complementary costs and protocol extensions will be added later.
Related papers
- Safeguards Based on Copyable Context Cannot Provide Reliable Safety for LLMsAnalysis / interpretabilityarXiv
- Adversarial Self-DistillationDefensesarXiv