CREBench: Evaluating Large Language Models in Cryptographic Binary Reverse Engineering

A benchmark of 432 cryptographic reverse-engineering challenges spanning 48 algorithms, 3 insecure key usage scenarios, and 3 levels of binary difficulty.

Baicheng Chen*1,6 Yu Wang*†4,5,1 Ziheng Zhou*2 Xiangru Liu4,5 Juanru Li‡7 Yilei Chen‡2,1 Tianxing He‡2,1,3
1Shanghai Qi Zhi Institute 2Institute of Interdisciplinary Information Sciences, Tsinghua University 3Xiongan AI Institute 4Institute of Information Engineering, Chinese Academy of Sciences 5University of Chinese Academy of Sciences 6The Chinese University of Hong Kong, Shenzhen 7East China Normal University

*Equal contribution. Project leader. Corresponding authors.

News

July 8, 2026: Our work is accepted by COLM 2026!

April 28, 2026: Our code is now available on GitHub! We have published all benchmark instances and evaluation scripts there.

April 5, 2026: The CREBench manuscript became available on arXiv.

Abstract

Reverse engineering is central to software security, particularly for cryptographic programs that handle sensitive data and are highly prone to vulnerabilities. CREBench studies the cryptographic binary reverse-engineering capabilities of large language models through 432 challenges built from 48 standard cryptographic algorithms, 3 insecure crypto key usage scenarios, and 3 difficulty levels. Each challenge follows a CTF-style reverse-engineering setting and is evaluated through four sub-tasks: algorithm identification, key or IV extraction, wrapper-level code reimplementation, and final flag recovery. Across eight frontier LLMs, GPT-5.4 achieves the best overall result with an average score of 64.04 out of 100 and a 59% flag recovery rate under pass@3, while the human expert baseline reaches 92.19 points.

432 Total benchmark challenges
48 Cryptographic algorithms
4 Evaluation sub-tasks per challenge
92.19 Human expert average score

Benchmark Overview

CREBench evaluates whether an LLM agent can autonomously reverse engineer cryptographic binaries in a sandboxed environment. Each challenge provides a stripped executable together with decompiled pseudocode, and the agent must analyze the program to recover the accepted plaintext input.

The benchmark is built by combining 48 standard cryptographic algorithms with three insecure key usage scenarios and three binary difficulty settings, yielding 48 × 3 × 3 = 432 instances. The four-task scoring ladder captures partial progress instead of treating reverse engineering as a pure pass-or-fail objective.

Overview of CREBench
Fig. 1. Overview of CREBench, including challenge construction dimensions and the four-stage evaluation framework.

Challenge construction. The three key usage settings are hardcoded keys, fragmented keys, and weak pseudo-random keys. The three binary difficulty settings are O0, O3, and Const-XOR, where the last one further obfuscates identifying cryptographic constants at runtime.

Leaderboard

CREBench is challenging and clearly separates models with substantially different reverse-engineering ability. GPT-5.4 ranks first with a total score of 64.04, followed by GPT-5.2 at 59.0. Performance is uneven across the pipeline: many models can partially recognize algorithms or locate candidate keys, but much fewer can reconstruct wrapper-level behavior and recover the final flag reliably.

Fig. 2. Pass@3 model performance on CREBench. Stacked bars show scores from algorithm identification, key or IV extraction, code reimplementation, and flag recovery.

Task 1: Algorithm Identification

Models must infer the implemented cipher from stripped binaries and decompiled pseudocode, often under compiler optimization or constant obfuscation.

Task 2: Key / IV Extraction

Agents recover embedded keys, fragmented material, or weak-PRNG-derived keys, and extract IVs when the instance requires them.

Task 3: Code Reimplementation

Agents must reconstruct wrapper-level encryption logic rather than only the cipher core, which requires sustained program understanding and reliable code synthesis.

Task 4: Flag Recovery

End-to-end plaintext recovery is the hardest stage because it depends on carrying the analysis all the way through with effective reasoning and tool use.

Difficulty and Subtask Analysis

Performance drops steadily from O0 to O3 and then to Const-XOR. Optimization mainly hurts code readability and data-flow tracing, while constant obfuscation destabilizes algorithm identification by hiding the signatures models often rely on.

Total Score by Difficulty

Average pass@3 total score under O0, O3, and Const-XOR.

Subtask Score by Difficulty

Subtask-level degradation across increasing binary difficulty.

Subtask Correlation

Task 3 and Task 4 show the strongest correlation, reflecting the link between correct code reconstruction and final flag recovery.

Further Analysis

A stricter end-to-end view comes from the pass@3 perfect rate, which counts a challenge only when the model solves all four sub-tasks. GPT-5.4 reaches the highest perfect rate at 41.0%, followed by GPT-5.2 at 30.1% and Claude-Sonnet-4.6 at 28.9%, while most remaining models stay well below that level.

Perfect Rate

Fraction of challenges solved perfectly with a score of 100/100 within three attempts.

Efficiency vs Performance

Average tokens per challenge versus overall pass@3 score, used to analyze cutoff sufficiency.

Observed Failure Modes

Manual log analysis highlights three recurring issues: prototype bias in algorithm identification, repeated low-level GDB loops after the high-level plan is lost, and a small number of explicit safety refusals on benchmark instances.

These patterns suggest that current LLM agents still struggle most with strategic control during dynamic analysis rather than with isolated static clues alone.

Case Study

Our work reports a successful AES-128-CBC reverse-engineering run where GPT-5.4 solves an O0 challenge with hardcoded keys in nine rounds. This example illustrates the full pipeline from structural recognition to key extraction, behavioral reconstruction, and flag recovery.

Successful AES reverse engineering case
Fig. 3. A successful CREBench trajectory: GPT-5.4 solves an AES-128-CBC benchmark instance end-to-end.

Human baseline. The human expert team evaluates the hardest Const-XOR subset under a two-hour limit per challenge and achieves 92.19 average points, with near-perfect key or IV extraction. Humans still maintain a substantial advantage on specialized cryptographic reverse engineering.

Limitations and Outlook

CREBench does not yet cover professional-grade obfuscation frameworks such as Tigress or O-LLVM. The paper focuses on cryptographic reverse engineering itself rather than extreme robustness to heavy obfuscation, partly because such binaries can become too bloated for current LLM context windows.

Even so, the benchmark already shows that frontier models can reverse engineer a non-trivial fraction of stripped crypto binaries. That makes capability tracking, stronger safeguards, and better understanding of agentic failure modes important future directions.

Citation

If you find CREBench useful, please cite:

@article{chen2026crebench,
  title={CREBench: Evaluating Large Language Models in Cryptographic Binary Reverse Engineering},
  author={Chen, Baicheng and Wang, Yu and Zhou, Ziheng and Liu, Xiangru and Li, Juanru and Chen, Yilei and He, Tianxing},
  journal={arXiv preprint arXiv:2604.03750},
  year={2026},
  url={https://arxiv.org/abs/2604.03750}
}