Skip to main content

Abstract

Blockchains allow the specification of contracts in the form of programs that guarantee their fulfilment. Nevertheless, errors in those programs can cause important, and often irretrievable, monetary loss. General-purpose languages provide a platform on which contracts can be built, but by their very generality they have the potential to exhibit behaviours of an unpredictable kind, and are also not easy to read or comprehend for general users.

An alternative solution is provided by domain-specific languages (DSLs), which are designed to express programs in a particular field. This paper explores the design of one DSL, Marlowe, targeted at the execution of financial contracts in the style of Peyton Jones et al. on blockchains. We present an executable semantics of Marlowe in Haskell, an example of Marlowe in practice, and describe the Meadow tool that allows users to interact in-browser with simulations of Marlowe contracts.

This work is part of the Cardano project and is supported by IOHK, https://iohk.io.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Notes

  1. 1.

    Named after Christopher Marlowe, the Elizabethan poet, dramatist and spy, who was born and educated in Canterbury, en.wikipedia.org/wiki/Christopher_Marlowe.

  2. 2.

    Marlowe is available from https://github.com/input-output-hk/scdsl.

References

  1. æternity: æternity (2018). https://aeternity.com

  2. Biryukov, A., Khovratovich, D., Tikhomirov, S.: Findel: secure derivative contracts for ethereum. In: Brenner, M., et al. (eds.) FC 2017. LNCS, vol. 10323, pp. 453–467. Springer, Cham (2017). https://doi.org/10.1007/978-3-319-70278-0_28

    Chapter  Google Scholar 

  3. Cardano: Why we are building Cardano (2017). https://whycardano.com

  4. Claessen, K., Hughes, J.: QuickCheck: a lightweight tool for random testing of Haskell programs. In: ICFP 2000, pp. 268–279. ACM (2000)

    Google Scholar 

  5. Done, C.: Fay (2012). https://github.com/faylang/fay/wiki. Accessed 14 May 2018

  6. Ekblad, A.: Haste (2012). https://haste-lang.org/. Accessed 26 Mar 2018

  7. Goodman, L.: Tezos - a self-amending crypto-ledger (2014). https://www.tezos.com/static/papers/white_paper.pdf

  8. Google: Blockly (2011). https://developers.google.com/blockly/. Accessed 26 Mar 2018

  9. Haverbeke, M., et al.: CodeMirror text editor (2011). https://codemirror.net/. Accessed 14 May 2018

  10. IELE Semantics (2016). https://github.com/runtimeverification/iele-semantics. Accessed 26 Mar 2018

  11. IOHK: The Cardano Project (2017). https://iohk.io/projects/cardano/

  12. Lamela Seijas, P., Thompson, S., McAdams, D.: Scripting smart contracts for distributed ledger technology. Cryptology ePrint Archive, Report 2016/1156 (2016). https://eprint.iacr.org/2016/1156

  13. Mackenzie, H., Nazarov, V., Stegeman, L.: GHCJS (2010). https://github.com/ghcjs/ghcjs. Accessed 14 May 2018

  14. Miller, M.: The digital path: smart contracts and the third world. In: Birner, J., Garrouste, P. (eds.) Markets, Information and Communication: Austrian Perspectives on the Internet Economy. Taylor and Francis (2004)

    Google Scholar 

  15. Nxt (2013). https://nxtplatform.org/. Accessed 26 Mar 2018

  16. Peyton Jones, S., et al.: Composing contracts: an adventure in financial engineering (functional pearl). In: Proceedings of the Fifth ACM SIGPLAN ICFP. ACM (2000)

    Google Scholar 

  17. Script - Bitcoin Wiki (2010). https://en.bitcoin.it. Accessed 26 Mar 2018

  18. Stenman, E.: The æternity system. CODE BEAM SF, March 2018. https://www.youtube.com/watch?v=VXsqvfPIdWg

  19. Wood, G.: Ethereum: a secure decentralised generalised transaction ledger. Ethereum Proj. Yellow Pap. 151, 1–32 (2014)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Simon Thompson .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2018 Springer Nature Switzerland AG

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Lamela Seijas, P., Thompson, S. (2018). Marlowe: Financial Contracts on Blockchain. In: Margaria, T., Steffen, B. (eds) Leveraging Applications of Formal Methods, Verification and Validation. Industrial Practice. ISoLA 2018. Lecture Notes in Computer Science(), vol 11247. Springer, Cham. https://doi.org/10.1007/978-3-030-03427-6_27

Download citation

  • DOI: https://doi.org/10.1007/978-3-030-03427-6_27

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-030-03426-9

  • Online ISBN: 978-3-030-03427-6

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics