Online detection of effectively callback free objects with applications to smart contracts
-
- Shelly Grossman
- Tel Aviv University, Israel
-
- Ittai Abraham
- VMware, USA
-
- Guy Golan-Gueta
- VMware, USA
-
- Yan Michalevsky
- Stanford University, USA
-
- Noam Rinetzky
- Tel Aviv University, Israel
-
- Mooly Sagiv
- Tel Aviv University, Israel / VMware, USA
-
- Yoni Zohar
- Tel Aviv University, Israel
説明
<jats:p>Callbacks are essential in many programming environments, but drastically complicate program understanding and reasoning because they allow to mutate object's local states by external objects in unexpected fashions, thus breaking modularity. The famous DAO bug in the cryptocurrency framework Ethereum, employed callbacks to steal $150M. We define the notion of Effectively Callback Free (ECF) objects in order to allow callbacks without preventing modular reasoning.</jats:p> <jats:p>An object is ECF in a given execution trace if there exists an equivalent execution trace without callbacks to this object. An object is ECF if it is ECF in every possible execution trace. We study the decidability of dynamically checking ECF in a given execution trace and statically checking if an object is ECF. We also show that dynamically checking ECF in Ethereum is feasible and can be done online. By running the history of all execution traces in Ethereum, we were able to verify that virtually all existing contract executions, excluding these of the DAO or of contracts with similar known vulnerabilities, are ECF. Finally, we show that ECF, whether it is verified dynamically or statically, enables modular reasoning about objects with encapsulated state.</jats:p>
収録刊行物
-
- Proceedings of the ACM on Programming Languages
-
Proceedings of the ACM on Programming Languages 2 (POPL), 1-28, 2017-12-27
Association for Computing Machinery (ACM)
- Tweet
詳細情報 詳細情報について
-
- CRID
- 1360857597737088768
-
- DOI
- 10.1145/3158136
-
- ISSN
- 24751421
-
- データソース種別
-
- Crossref