深度学习在漏洞检测中展示了早期基准的有希望的结果,但最近的评估揭示了灾难性退化:在传统数据集上实现F1>0.68的模型在严格去重下降至0.031。我们识别出根本原因是语义模糊问题:相同代码可以是安全或易受攻击的,取决于项目特定的行为合同,使全局分类从根本上不足。我们提出Phoenix,一种无训练的多智能体框架,通过行为合同合成解决这一模糊性。Phoenix将检测分解为三个阶段:语义切片器提取最小的漏洞相关上下文,需求反向工程师合成Gherkin行为规范编码的安全合同,以及合同法官通过严格合规检查评估代码。在PrimeVul Paired上,Phoenix实现F1=0.825和Pair-Correct=64.4%,超越RASM-Vul(F1=0.668)和VulTrial(F1=0.563),同时使用开源模型小48倍(7-14B vs. 671B)。25种配置的消融分析显示Gherkin规范是决定性驱动因素(+0.09至+0.35 F1)。错误分析揭示18%的“假阳性”识别出修补代码中的真实安全问题,证明安全是相对于行为合同定义的属性,而不是代码语法的绝对属性。
英文摘要:
Deep learning for vulnerability detection has shown promising results on early benchmarks, but recent evaluations reveal catastrophic degradation: models achieving F1 > 0.68 on legacy datasets collapse to 0.031 under strict deduplication. We identify the root cause as the semantic ambiguity problem: identical code can be secure or vulnerable depending on project-specific behavioral contracts, rendering global classification fundamentally inadequate. We propose Phoenix, a training-free multi-agent framework that resolves this ambiguity through Behavioral Contract Synthesis. Phoenix decomposes detection into three stages: a Semantic Slicer extracting minimal vulnerability-relevant context, a Requirement Reverse Engineer synthesizing Gherkin behavioral specifications encoding the security contract, and a Contract Judge evaluating code against these specifications via strict compliance checking. On PrimeVul Paired, Phoenix achieves F1 = 0.825 and Pair-Correct = 64.4%, surpassing RASM-Vul (F1 = 0.668) and VulTrial (F1 = 0.563) while using open-source models up to 48x smaller (7-14B vs. 671B). Ablation across 25 configurations demonstrates Gherkin specifications as the decisive driver (+0.09 to +0.35 F1). Error analysis reveals 18% of "False Positives" identify genuine security concerns in patched code, demonstrating that security is a relative property defined against behavioral contracts, not an absolute property of code syntax.
Automated Vulnerability Injection in Smart Contracts Using Large Language Models
Università degli Studi di Napoli Federico II(那不勒斯费德里科二世大学);Gran Sasso Science Institute (GSSI)(格兰萨索科学研究所);University of Coimbra(科英布拉大学);College of Computing and Informatics, University of North Carolina at Charlotte(北卡罗来纳大学夏洛特分校计算与信息学院)
Knowledge Over Parameters: Evolving Smart Contract Vulnerability Detection
Nanyang Technological University(南洋理工大学);Nankai University(南开大学);University of California, Los Angeles(加州大学洛杉矶分校);Imperial College London(伦敦帝国学院);Singapore Management University(新加坡管理大学)
ESCORT: Ethereum Smart COntRacTs Vulnerability Detection using Deep Neural Network and Transfer Learning
University of Würzburg(维尔茨堡大学);University of California, San-Diego(加利福尼亚大学圣地亚哥分校);Technical University of Darmstadt(达姆施塔特工业大学);University of California, San Diego(加利福尼亚大学圣地亚哥分校)
Dual-view Aware Smart Contract Vulnerability Detection for Ethereum
Institute of Cyberspace Security, Zhejiang University of Technology(浙江工业大学网络空间安全研究院);Binjiang Institute of Artificial Intelligence, ZJUT(浙江工业大学滨江人工智能研究院)
ContractShield: Bridging Semantic-Structural Gaps via Hierarchical Cross-Modal Fusion for Multi-Label Vulnerability Detection in Obfuscated Smart Contracts
University of Information Technology(信息技术大学);Vietnam National University Ho Chi Minh City(越南国家大学胡志明市分校);VNU-HCM Information Security Center(胡志明市越南国家大学信息安全中心);Singapore Institute of Technology(新加坡理工学院)
On the Shoulders of Giants: Empowering Automated Smart Contract Auditing via the GiAnt Corpus
Zhejiang University(浙江大学);Hangzhou High-Tech Zone (Binjiang) Institute of Blockchain and Data Security(杭州高新技术区(滨江)区块链与数据安全研究所);University of Ottawa(渥太华大学)
SAEL: Leveraging Large Language Models with Adaptive Mixture-of-Experts for Smart Contract Vulnerability Detection
Institute of Software, Chinese Academy of Sciences(中国科学院软件研究所);University of Chinese Academy of Sciences(中国科学院大学);State Key Laboratory of Computer Science, Institute of Software, Chinese Academy of Sciences(中国科学院软件研究所计算机科学技术国家重点实验室)
Knowdit: Agentic Smart Contract Vulnerability Detection with Auditing Knowledge Summarization
Nanyang Technological University(南洋理工大学);National Superior College for Engineers, Beihang University(北京航空航天大学高等工程学院);Bitslab;The Chinese University of Hong Kong(香港中文大学)
MTVHunter: Smart Contracts Vulnerability Detection Based on Multi-Teacher Knowledge Translation
College of Computer Science and Technology, Harbin Engineering University(哈尔滨工程大学计算机科学与技术学院);Zhejiang University(浙江大学);Hangzhou High-Tech Zone (Binjiang) Institute of Blockchain and Data Security(杭州高新区(滨江)区块链与数据安全研究院)
Smart Contracts Claimed Vulnerable by the CVE Database, with Labels and Source Locations
Institute of Computer Engineering, Informatics, TU Wien(TU Wien 计算机工程与信息学研究所);Division of Theoretical Computer ScienceKTH Royal Institute of Technology(KTH皇家理工学院理论计算机科学系);Institute of Logic and Computation, Informatics, TU Wien(TU Wien 逻辑与计算信息学研究所)