arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2604.26495cs.CR
收藏

超越代码推理:一种基于规范的审计框架用于专家增强的安全验证

Beyond Code Reasoning: A Specification-Anchored Audit Framework for Expert-Augmented Security Verification

Nyx Foundation(Nyx基金会);Aichi Prefectural Aichi High School of Technology and Engineering(爱知县爱知科学技术高等学校);Department of Physics, Kyoto University(京都大学物理学系)

Masato Kamba, Hirotake Murakami, Akiyoshi Sannai

AI总结:

本文提出SPECA框架,通过自然语言规范生成类型化安全属性,实现基于规范的审计,解决代码层面无法检测规范依赖漏洞的问题,提升安全验证的准确性和可解释性。

摘要:

安全关键软件通常通过工具审计漏洞,这些工具将漏洞视为仓库本地的代码模式。然而,受规范指导的系统——协议栈、共识实现、密码学库——受自然语言规范中定义的不变量和正确性条件约束。当漏洞源于规范要求而非代码编写方式时,代码层面的方法缺乏检测词汇,其假阳性难以系统诊断。本文提出SPECA,一种基于规范的安全审计框架,从自然语言规范中推导出显式、类型化的安全属性,并通过结构化证明尝试推理进行审计。该框架具备三种代码驱动审计所缺乏的能力:规范依赖的检测、在共享属性词汇下的受控跨实现比较,以及可分解为可解释、管道阶段可追溯的根因的假阳性。在Sherlock Ethereum Fusaka审计竞赛(366份提交,10个实现)中,SPECA恢复了所有15个在场漏洞,并独立发现了4个由开发人员修复提交确认的bug。在RepoAudit C/C++基准(15个项目)中,SPECA匹配了最佳发布的精度(88.9%),并揭示了12个候选bug,其中两个由上游维护者确认。多模型分析表明,更强大的模型在属性范围内审计更忠实,将检测瓶颈从模型推理转移到属性生成质量。所有假阳性均追溯到三个反复出现的根因——信任边界误解、代码阅读错误和规范误解——每个都产生可操作的改进目标。

英文摘要:

Security-critical software is routinely audited by tools that reason about vulnerabilities as repository-local code patterns. Yet specification-governed systems -- protocol stacks, consensus implementations, cryptographic libraries -- are constrained by invariants and correctness conditions defined in natural-language specifications. When a vulnerability arises from what the specification requires rather than how code is written, code-level approaches lack the representational vocabulary to detect it, and their false positives resist systematic diagnosis. We present SPECA, a specification-anchored security audit framework that derives explicit, typed security properties from natural-language specifications and audits implementations through structured proof-attempt reasoning grounded in each property. The framework yields three capabilities absent from code-driven auditing: spec-dependent detections, controlled cross-implementation comparison under a shared property vocabulary, and false positives that decompose into interpretable, pipeline-phase-traceable root causes. On the Sherlock Ethereum Fusaka Audit Contest (366 submissions, 10 implementations), SPECA recovers all 15 in-scope vulnerabilities and independently discovers 4 bugs confirmed by developer fix commits. On the RepoAudit C/C++ benchmark (15 projects), SPECA matches the best published precision (88.9\%) while surfacing 12 candidate bugs beyond the established ground truth, two confirmed by upstream maintainers. A multi-model analysis reveals that more capable models audit more faithfully within property scope, shifting the detection bottleneck from model reasoning to property generation quality. All false positives trace to three recurring root causes -- trust boundary misunderstanding, code reading errors, and specification misinterpretation -- each yielding actionable improvement targets.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑