Solidity的可执行操作语义
Executable Operational Semantics of Solidity
摘要:
比特币最近引起了大家的关注和兴趣。以太坊(ETH)是第二代加密货币,它通过提供一种名为Solidity的图灵完备程序设计语言来开发智能合约,从而扩展了比特币的设计。智能合约允许在没有第三方的情况下在EVM(以太坊虚拟机)上可信地执行合约。开发正确的智能合约是具有挑战性的,因为它的分散计算性质。错误的智能合约可能会导致巨大的财务损失。此外,智能合约一旦部署,即使不是不可能,也很难打补丁。因此,最近对分析/验证智能合约的兴趣激增。虽然现有的工作主要集中在EVM操作码上,但我们认为理解和定义Solidity的语义同样重要,因为程序员在源代码级别对智能合约进行编程和推理。在这项工作中,我们开发了Solidity的结构操作语义,这使我们能够识别出许多有问题的智能合约中的多个设计问题。此外,我们的语义在K框架中是可执行的,这允许我们自动验证/伪造合同。
英文摘要:
Bitcoin has attracted everyone's attention and interest recently. Ethereum (ETH), a second generation cryptocurrency, extends Bitcoin's design by offering a Turing-complete programming language called Solidity to develop smart contracts. Smart contracts allow creditable execution of contracts on EVM (Ethereum Virtual Machine) without third parties. Developing correct smart contracts is challenging due to its decentralized computation nature. Buggy smart contracts may lead to huge financial loss. Furthermore, smart contracts are very hard, if not impossible, to patch once they are deployed. Thus, there is a recent surge of interest on analyzing/verifying smart contracts. While existing work focuses on EVM opcode, we argue that it is equally important to understand and define the semantics of Solidity since programmers program and reason about smart contracts at the level of source code. In this work, we develop the structural operational semantics for Solidity, which allows us to identify multiple design issues which underlines many problematic smart contracts. Furthermore, our semantics is executable in the K framework, which allows us to verify/falsify contracts automatically.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。