Table of Contents
Fetching ...

Constructing Trustworthy Smart Contracts

Devora Chait-Roth, Kedar S. Namjoshi

TL;DR

ASP, a system aimed at easing the construction of provably secure contracts, is introduced, a system consists of three closely-linked components: a programming language, a defensive compiler, and a proof checker.

Abstract

Smart contracts form the core of Web3 applications. Contracts mediate the transfer of cryptocurrency, making them irresistible targets for hackers. We introduce ASP, a system aimed at easing the construction of provably secure contracts. The Asp system consists of three closely-linked components: a programming language, a defensive compiler, and a proof checker. The language semantics guarantee that Asp contracts are free of commonly exploited vulnerabilities such as arithmetic overflow and reentrancy. The defensive compiler enforces the semantics and translates Asp to Solidity, the most popular contract language. Deductive proofs establish functional correctness and freedom from critical vulnerabilities such as unauthorized access.

Constructing Trustworthy Smart Contracts

TL;DR

ASP, a system aimed at easing the construction of provably secure contracts, is introduced, a system consists of three closely-linked components: a programming language, a defensive compiler, and a proof checker.

Abstract

Smart contracts form the core of Web3 applications. Contracts mediate the transfer of cryptocurrency, making them irresistible targets for hackers. We introduce ASP, a system aimed at easing the construction of provably secure contracts. The Asp system consists of three closely-linked components: a programming language, a defensive compiler, and a proof checker. The language semantics guarantee that Asp contracts are free of commonly exploited vulnerabilities such as arithmetic overflow and reentrancy. The defensive compiler enforces the semantics and translates Asp to Solidity, the most popular contract language. Deductive proofs establish functional correctness and freedom from critical vulnerabilities such as unauthorized access.

Paper Structure

This paper contains 21 sections, 6 figures.

Figures (6)

  • Figure 1: The Asp pipeline. The Viper system is used to verify proof assertions.
  • Figure 2: Skeleton of an open auction contract in Asp
  • Figure 3: Code snippets of open auction contract and receiving contract in Asp
  • Figure 4: Open auction contract with ghost variables
  • Figure 5: Two contracts that demonstrate limited reentrancy in Asp's cascade semantics.
  • ...and 1 more figures