An Empirical Analysis of Smart Contracts: Platforms, Applications, and Design Patterns

  • Massimo BartolettiEmail author
  • Livio Pompianu
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 10323)


Smart contracts are computer programs that can be consistently executed by a network of mutually distrusting nodes, without the arbitration of a trusted authority. Because of their resilience to tampering, smart contracts are appealing in many scenarios, especially in those which require transfers of money to respect certain agreed rules (like in financial services and in games). Over the last few years many platforms for smart contracts have been proposed, and some of them have been actually implemented and used. We study how the notion of smart contract is interpreted in some of these platforms. Focussing on the two most widespread ones, Bitcoin and Ethereum, we quantify the usage of smart contracts in relation to their application domain. We also analyse the most common programming patterns in Ethereum, where the source code of smart contracts is available.



This work is partially supported by Aut. Reg. of Sardinia project P.I.A. 2013 “NOMAD”.


  1. 1.
    Bitcoin contract. Accessed 14 Jan 2017
  2. 2.
    Bitcoin OP_RETURN wiki page. Accessed 14 Jan 2017
  3. 3.
    Dgx website. Accessed 14 Jan 2017
  4. 4.
    Ethereum hard fork 20 July 2016. Accessed 14 Jan 2017
  5. 5.
    Ethereum request for comment 20. Accessed 14 Jan 2017
  6. 6.
    Lisk. Accessed 14 Jan 2017
  7. 7.
    Making sense of blockchain smart contracts. Accessed 14 Jan 2017
  8. 8.
    Monax. Accessed 14 Jan 2017
  9. 9.
    Smart contracts: The good, the bad and the lazy. Accessed 14 Jan 2017
  10. 10.
    Stellar. Accessed 14 Jan 2017
  11. 11.
    The Stellar consensus protocol. Accessed 14 Jan 2017
  12. 12.
    Thinking about smart contract security. Accessed 14 Jan 2017
  13. 13.
    Understanding the DAO attack. Accessed 14 Jan 2017
  14. 14.
    Another bug in the ens, you can win with an unlimited high bid without paying for it (2017). Accessed 17 Mar 2017
  15. 15.
    Anderson, L., Holz, R., Ponomarev, A., Rimba, P., Weber, I.: New kids on the block: an analysis of modern blockchains. CoRR abs/1606.06530 (2016)Google Scholar
  16. 16.
    Andrychowicz, M., Dziembowski, S., Malinowski, D., Mazurek, L.: Secure multiparty computations on Bitcoin. In: IEEE S & P, pp. 443–458 (2014)Google Scholar
  17. 17.
    Andrychowicz, M., Dziembowski, S., Malinowski, D., Mazurek, L.: Secure ultiparty computations on Bitcoin. Commun. ACM 59(4), 76–84 (2016). CrossRefGoogle Scholar
  18. 18.
    Atzei, N., Bartoletti, M., Cimoli, T.: A survey of attacks on ethereum smart contracts (SoK). In: Maffei, M., Ryan, M. (eds.) POST 2017. LNCS, vol. 10204, pp. 164–186. Springer, Heidelberg (2017). CrossRefGoogle Scholar
  19. 19.
    Back, A., Bentov, I.: Note on fair coin toss via Bitcoin (2013).
  20. 20.
    Banasik, W., Dziembowski, S., Malinowski, D.: Efficient zero-knowledge contingent payments in cryptocurrencies without scripts. In: Askoxylakis, I., Ioannidis, S., Katsikas, S., Meadows, C. (eds.) ESORICS 2016. LNCS, vol. 9879, pp. 261–280. Springer, Cham (2016). CrossRefGoogle Scholar
  21. 21.
    Baqer, K., Huang, D.Y., McCoy, D., Weaver, N.: Stressing out: Bitcoin “stress testing”. In: Clark, J., Meiklejohn, S., Ryan, P.Y.A., Wallach, D., Brenner, M., Rohloff, K. (eds.) FC 2016. LNCS, vol. 9604, pp. 3–18. Springer, Heidelberg (2016). CrossRefGoogle Scholar
  22. 22.
    Bartoletti, M., Carta, S., Cimoli, T., Saia, R.: Dissecting Ponzi schemes on Ethereum: identification, analysis, and impact. CoRR abs/1703.03779 (2017).
  23. 23.
    Bartoletti, M., Pompianu, L.: An analysis of Bitcoin OP_RETURN metadata. CoRR abs/1702.01024 (2016). To appear in Bitcoin Workshop 2017.
  24. 24.
    Bentov, I., Kumaresan, R.: How to use Bitcoin to design fair protocols. In: Garay, J.A., Gennaro, R. (eds.) CRYPTO 2014. LNCS, vol. 8617, pp. 421–439. Springer, Heidelberg (2014). CrossRefGoogle Scholar
  25. 25.
    Bhargavan, K., Delignat-Lavaud, A., Fournet, C., Gollamudi, A., Gonthier, G., Kobeissi, N., Rastogi, A., Sibut-Pinote, T., Swamy, N., Zanella-Beguelin, S.: Formal verification of smart contracts. In: PLAS (2016)Google Scholar
  26. 26.
    Bonneau, J., Miller, A., Clark, J., Narayanan, A., Kroll, J.A., Felten, E.W.: SoK: research perspectives and challenges for Bitcoin and cryptocurrencies. In: IEEE S & P, pp. 104–121 (2015)Google Scholar
  27. 27.
    Brown, R.G., Carlyle, J., Grigg, I., Hearn, M.: Corda: an introduction (2016).
  28. 28.
    Buterin, V.: Ethereum: a next generation smart contract and decentralized application platform (2013).
  29. 29.
    Churyumov, A.: Byteball: a decentralized system for transfer of value (2016).
  30. 30.
    Clack, C.D., Bakshi, V.A., Braine, L.: Smart contract templates: foundations, design landscape and research directions. CoRR abs/1608.00771 (2016)Google Scholar
  31. 31.
    Delmolino, K., Arnett, M., Kosba, A., Miller, A., Shi, E.: Step by step towards creating a safe smart contract: lessons and insights from a cryptocurrency lab. In: Clark, J., Meiklejohn, S., Ryan, P.Y.A., Wallach, D., Brenner, M., Rohloff, K. (eds.) FC 2016. LNCS, vol. 9604, pp. 79–94. Springer, Heidelberg (2016). CrossRefGoogle Scholar
  32. 32.
    Dermody, R., Krellenstein, A., Slama, O., Wagner, E.: Counterparty: Protocol specification (2014). Accessed 14 Jan 2017
  33. 33.
    Frantz, C.K., Nowostawski, M.: From institutions to code: towards automated generation of smart contracts. In: Workshop on Engineering Collective Adaptive Systems (eCAS) (2016)Google Scholar
  34. 34.
    Glaser, F., Zimmermann, K., Haferkorn, M., Weber, M.C.: Bitcoin - asset or currency? revealing users’ hidden intentions. In: European Conference on Information Systems (ECIS) (2014)Google Scholar
  35. 35.
    Grau, P.: Lessons learned from making a chess game for Ethereum (2016). Accessed 14 Jan 2017
  36. 36.
    Kumaresan, R., Moran, T., Bentov, I.: How to use Bitcoin to play decentralized poker. In: ACM CCS, pp. 195–206 (2015)Google Scholar
  37. 37.
    Luu, L., Chu, D.H., Olickel, H., Saxena, P., Hobor, A.: Making smart contracts smarter. In: ACM CCS (2016).
  38. 38.
    Marino, B., Juels, A.: Setting standards for altering and undoing smart contracts. In: Alferes, J.J.J., Bertossi, L., Governatori, G., Fodor, P., Roman, D. (eds.) RuleML 2016. LNCS, vol. 9718, pp. 151–166. Springer, Cham (2016). CrossRefGoogle Scholar
  39. 39.
    Möser, M., Böhme, R.: Trends, tips, tolls: a longitudinal study of Bitcoin transaction fees. In: Brenner, M., Christin, N., Johnson, B., Rohloff, K. (eds.) FC 2015. LNCS, vol. 8976, pp. 19–33. Springer, Heidelberg (2015). CrossRefGoogle Scholar
  40. 40.
    Nakamoto, S.: Bitcoin: a peer-to-peer electronic cash system (2008).
  41. 41.
    Nomura Research Institute: Survey on blockchain technologies and related services.
  42. 42.
    Popejoy, S.: The Pact smart contract language (2016).
  43. 43.
    Reid, F., Harrigan, M.: An analysis of anonymity in the Bitcoin system. In: Altshuler, Y., Elovici, Y., Cremers, A., Aharony, N., Pentland, A. (eds.) Security and Privacy in Social Networks, pp. 197–223. Springer, Heidelberg (2013). CrossRefGoogle Scholar
  44. 44.
    Ron, D., Shamir, A.: Quantitative analysis of the full Bitcoin transaction graph. In: Sadeghi, A.-R. (ed.) FC 2013. LNCS, vol. 7859, pp. 6–24. Springer, Heidelberg (2013). CrossRefGoogle Scholar
  45. 45.
    Seijas, P.L., Thompson, S., McAdams, D.: Scripting smart contracts for distributed ledger technology. Cryptology ePrint Archive, Report 2016/1156 (2016).
  46. 46.
    Sompolinsky, Y., Zohar, A.: Secure high-rate transaction processing in Bitcoin. In: Böhme, R., Okamoto, T. (eds.) FC 2015. LNCS, vol. 8975, pp. 507–527. Springer, Heidelberg (2015). CrossRefGoogle Scholar
  47. 47.
    Szabo, N.: Formalizing and securing relationships on public networks. First Monday 2(9) (1997).
  48. 48.
    UK Government Chief Scientific Adviser: Distributed ledger technology: beyond block chain.
  49. 49.
    Wood, G.: Ethereum: a secure decentralised generalised transaction ledger (2014).

Copyright information

© International Financial Cryptography Association 2017

Authors and Affiliations

  1. 1.Università degli Studi di CagliariCagliariItaly

Personalised recommendations