Declarative Smart Contracts
Haoxian Chen, Gerald Whitters, Mohammad Javad Amiri, Yuepeng Wang,, Boon Thau Loo

TL;DR
DeCon is a declarative language for smart contracts that models contracts as relational tables, enabling easier specification, monitoring, and debugging, with minimal runtime overhead.
Contribution
This work introduces DeCon, a relational-based declarative language for smart contracts, along with a compiler to Solidity and runtime monitoring capabilities.
Findings
DeCon can implement ERC20 and ERC721 tokens.
DeCon incurs 14% median gas overhead for execution.
DeCon adds 16% median gas overhead for runtime verification.
Abstract
This paper presents DeCon, a declarative programming language for implementing smart contracts and specifying contract-level properties. Driven by the observation that smart contract operations and contract-level properties can be naturally expressed as relational constraints, DeCon models each smart contract as a set of relational tables that store transaction records. This relational representation of smart contracts enables convenient specification of contract properties, facilitates run-time monitoring of potential property violations, and brings clarity to contract debugging via data provenance. Specifically, a DeCon program consists of a set of declarative rules and violation query rules over the relational representation, describing the smart contract implementation and contract-level properties, respectively. We have developed a tool that can compile DeCon programs into…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Code & Models
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsBlockchain Technology Applications and Security · Advanced Data Storage Technologies · Scientific Computing and Data Management
