[论文解读] Securify: Practical Security Analysis of Smart Contracts
Securify 是一个可扩展的、自动化的以太坊智能合约安全验证器,它利用对语义事实进行分层 Datalog 编码的领域特定合规与违规模式,将行为分类为违规、警告或合规。
Permissionless blockchains allow the execution of arbitrary programs (called smart contracts), enabling mutually untrusted entities to interact without relying on trusted third parties. Despite their potential, repeated security concerns have shaken the trust in handling billions of USD by smart contracts. To address this problem, we present Securify, a security analyzer for Ethereum smart contracts that is scalable, fully automated, and able to prove contract behaviors as safe/unsafe with respect to a given property. Securify's analysis consists of two steps. First, it symbolically analyzes the contract's dependency graph to extract precise semantic information from the code. Then, it checks compliance and violation patterns that capture sufficient conditions for proving if a property holds or not. To enable extensibility, all patterns are specified in a designated domain-specific language. Securify is publicly released, it has analyzed >18K contracts submitted by its users, and is regularly used to conduct security audits by experts. We present an extensive evaluation of Securify over real-world Ethereum smart contracts and demonstrate that it can effectively prove the correctness of smart contracts and discover critical violations.
研究动机与目标
- 在高调的利用和金融损失的背景下,推动对安全智能合约的需求。
- 引入一个面向实际安全属性的领域特定验证器(Securify),通过基于模式的推理进行目标定位。
- 展示一个可扩展的端到端实现,能够自动化分析合约。
- 证明 Securify 能在真实的以太坊合约上证明正确性并揭示违规行为。
提出的方法
- 将 EVM 字节码反编译为 SSA 形式,以获得合约的无栈表示。
- 使用声明性分层 Datalog 规则推断关于控制流和数据流的语义事实。
- 检查用 DSL 表达的一组合规和违规模式,以证明或反驳属性。
- 将属性表示为模式,意味着安全性(合规)或否定(违规)。
- 基于模式匹配将合约行为分类为违规、警告或合规结果。
- 通过允许安全专家通过 DSL 增加新模式,提供可扩展性。
实验结果
研究问题
- RQ1模式化的合规和违规是否能捕捉到智能合约的实际安全属性?
- RQ2Securify 能否在真实合约上自动证明或反驳这些属性?
- RQ3基于 DSL 的模式方法在应对不断演进的安全需求时是否具有可扩展性?
- RQ4就覆盖范围和误报/漏报而言,Securify 与现有符号分析器相比表现如何?
主要发现
- Securify 分析了用户提交的超过 18,000 份合约。
- 分析器通常可以在几秒钟内对合约完成分析。
- 基于模式的检查显著降低警告的人工检查工作量(对于某些属性,减少了 65.9% 到 99.4%)。
- Securify 报告所有不安全行为,降低遗漏关键违规的概率。
- 该系统已在 38 次详细的商业审计中使用,并且仍被审计人员积极使用。
- 该方法在真实的以太坊合约上证明合约正确性并发现违规行为方面展现出有效性。
更好的研究,从现在开始
从论文设计到论文写作,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。