一句话:提出 PSR² 协同静态分析框架,融合图结构搜索与确定性语义推理,精化合约模型以高效检测原子性违反。
针对去中心化应用中 Oracle、NFT 等复杂智能合约的原子性违反问题,传统静态分析器因规则僵化、缺乏深层上下文感知而导致误报与漏报率偏高。本文提出 PSR² 协同静态分析框架,将结构路径搜索与确定性语义推理相结合:图结构分析模块(GSAM)在控制流图中识别可疑执行序列,语义上下文分析模块(SCAM)从抽象语法树中抽取数据依赖与状态事实,融合决策模块(FDM)基于统一的原子性不一致模型进行形式化交叉验证。在 1600 个合约样本上的实验表明,PSR² 在复杂 ERC-721 场景中 F1 分数达 94.69%,显著优于模式匹配基线的 51.86%;消融研究进一步证实,融合逻辑相较单模块分析可将误报率降低近一半。
With the rapid advancement of decentralized applications, smart contract security faces severe challenges, particularly regarding atomicity violations in complex logic such as Oracle and NFT contracts. Rigid rule sets often limit traditional static analyzers and lack deep contextual awareness, leading to high false-positive and false-negative rates when identifying vulnerabilities that depend on intermediate state inconsistencies. To address these limitations, this paper proposes PSR2, a novel collaborative static analysis framework that integrates structural path searching with deterministic semantic reasoning. PSR2 utilizes a Graph Structure Analysis Module (GSAM) to identify suspicious execution sequences in control flow graphs and a Semantic Context Analysis Module (SCAM) to extract data dependencies and state facts from abstract syntax trees. A Fusion Decision Module (FDM) then performs formal cross validation to confirm vulnerabilities based on a unified atomicity inconsistency model. Experimental results on 1,600 contract samples demonstrate that PSR2 significantly outperforms pattern-matching baselines, achieving an F1-score of 94.69% in complex ERC-721 scenarios compared to 51.86% for existing tools. Ablation studies further confirm that our fusion logic effectively reduces the false-positive rate by nearly half compared to single module analysis.
DOI 原文 · arXiv · PDF(开放获取) · DBLP
@inproceedings{abs-2604-06975,
title = {PSR²: A Phase-based Semantic Reasoning Framework for Atomicity Violation Detection via Contract Refinement},
author = {Xiaoqi Li and Xin Wang and Wenkai Li and Zongwei Li},
booktitle = {FSE},
year = {2026},
doi = {10.1145/3803437.3805575}
}