arXiv:2609.35434cs.CRSep 2026

Manuscript Offprint

arXiv:2609.35434

LLM-Assisted Automatic Security Proofs for Cryptographic Protocols: How Far Are We?

Tianjian Liu, Shicheng Feng, Jin'ao Shang, Xiaoting Lyu, Bin Wang, Zonghua Zhang, Lei Xue, Wei Wang

Tianjian Liu*‖, Shicheng Feng†, Jin'ao Shang*, Xiaoting Lyu*, Bin Wang‡, Zonghua Zhang§, Lei Xue¶*, Wei Wang**

*Xi'an Jiaotong University, Xi'an, China

{tianjian.liu, jinao_s}@stu.xjtu.edu.cn, {xiaoting.lyu, wei.wang}@xjtu.edu.cn

†Tianjin University, Tianjin, China

fengshicheng@tju.edu.cn

†^{\dagger}Zhejiang Key Laboratory of Artificial Intelligence of Things (AIoT) Network and Data Security

wangbin02@xidian.edu.cn

§CRSC Research & Design Institute Group Co., Ltd

zhangzonghua@crscd.com.cn

Sun Yat-sen University, Guangzhou, China

xuelei3@mail.sysu.edu.cn

||Shenzhen Loop Area Institute, Shenzhen, China

*Corresponding authors: Lei Xue and Wei Wang.

Abstract—Large language models (LLMs) have shown strong potential for assisting software and security analysis tasks, yet their effectiveness in cryptographic symbolic protocol verification remains insufficiently understood.

In this paper, we conduct the first systematic evaluation of the capability of state-of-the-art LLMs in cryptographic symbolic protocol verification. To quantify this capability, we propose CROST (Coverage Rate of Solve Tree), a proof-based metric derived from the verifier's proof skeleton that measures the similarity between generated lemmas and reference lemmas. We then establish the rationale of CROST through both theoretical analysis and empirical validation. The evaluation results show that state-of-the-art models achieve 38.82% coverage on average, with 14.4% of generated lemmas exceeding 80% coverage, indicating that LLMs can already generate useful lemmas to a certain extent. However, they still exhibit non-trivial failure modes on complex multi-phase protocols, show diminishing returns under naive scaling, and incur substantial verification overhead. These findings clarify the practical potential and limitations of LLMs for protocol verification and motivate future work on complex real-world protocols.

Index Terms—LLM, Formal verification, Cryptographic protocol, Symbolic model

I. INTRODUCTION

Cryptographic protocols are designed to coordinate security-critical interactions and achieve security goals such as secrecy and authentication. In symbolic models, these goals are formalized as security properties over protocol executions, enabling verification tools to reason about whether an active adversary can break them. This style of analysis has proved practically valuable by exposing subtle flaws in widely deployed or standardized protocols, e.g., PCS violations enabled by Signal's session handling layer [1], multiple confirmed vulnerabilities in Apple/Samsung proximity tracking protocols [2], and critical attacks on the EMV payment standard [3].

However, as shown in Figure 1, completing a protocol verification typically involves (Step 1) formalizing the cryptographic protocol, (Step 2) defining security properties, and (Step 3) analyzing counterexample traces [4]. This process still requires substantial expert knowledge and manual effort [2], [5]–[7]. As reported by the Galois team [8], formally verifying the AES-256-GCM and SHA-384 implementations in AWS LibCrypto required approximately nine person-months of work by experienced proof engineers.

Figure

Fig. 1. Symbolic model verification pipeline.

Recent advances in LLMs [9]–[13] suggest a possible route for automatically extracting unambiguous and analyzable specifications, thereby lowering the barrier to applying formal methods. Prior work on combining LLMs with symbolic model verification tools for cryptographic protocols has mainly studied the translation of natural-language protocol descriptions into tool-checkable symbolic models (Step 1) [14]. However, the complementary task of specifying security properties (Step 2) remains largely manual. Symbolic verifiers require explicit security goals as input, and these goals must be written as tool-checkable lemmas. Writing and refining such lemmas requires expert knowledge; it also determines what the verifier actually checks and how difficult the subsequent proof search becomes [15]–[18]. We therefore focus on security-property specification for already available protocol models, and study whether LLMs can generate tool-checkable security properties in Cryptographic Symbolic Protocol Verification (CSPV) (Step 2).

To answer this question, this paper presents a systematic empirical study that focuses on two research questions:

• What are the capability boundaries of LLMs for security-property generation in CSPV?

• How do LLMs perform across different task types in CSPV?

There are two challenges in answering the above questions.

First, due to the diversity of representations (We will give an example in Section III-A) for the same security property, it is difficult to measure the similarity between a generated security property and a target correct security property using simple text-based comparison. To capture deeper features of security properties in the verification process, we introduce a proof-based metric derived from Tamarin's proof skeleton, which reflects security properties feature at the proof-search layer [15], [16]. We further justify the rationale and effectiveness of this metric through theoretical analysis and mutation-based empirical validation.

Second, symbolic protocol verification tools such as Tamarin use domain-specific specification languages to describe protocols and their security properties. In such languages, security properties often involve temporal semantics, deeply nested logical structures, and protocol-specific constraints. These characteristics make it difficult for LLMs to generate syntactically correct security properties, even when the intended property is conceptually simple [19]. In this work, we therefore investigate the effect of few-shot prompting on LLM-based security property generation and evaluate whether lightweight in-context examples can improve syntactic validity and downstream verification performance.

In summary, our contributions are as follows:

• We present the first systematic empirical study of LLM capability in CSPV tasks of secrecy, authentication, and sanity. Our evaluation shows that LLMs exhibit stronger performance on existential propositions.

• We propose a solve-level coverage metric named CRoST (Coverage Rate of Solve Tree) for quantifying security properties similarity, and validate its rationality through both theoretical analysis and mutation-based evaluation.

• We unveil the main limitations and failure modes of mainstream LLMs when they are applied in CSPV tasks. We show that stage-point confusion in complex multi-phase protocols and substantial time overhead are two major bottlenecks for using LLMs in CSPV.

References (45)