Towards a Formal Verification of the Lightning Network with TLA+
Abstract: Payment channel networks are an approach to improve the scalability of blockchain-based cryptocurrencies. Because payment channel networks are used for transfer of financial value, their security in the presence of adversarial participants should be verified formally. We formalize the protocol of the Lightning Network, a payment channel network built for Bitcoin, and show that the protocol fulfills the expected security properties. As the state space of a specification consisting of multiple participants is too large for model checking, we formalize intermediate specifications and use a chain of refinements to validate the security properties where each refinement is justified either by model checking or by a pen-and-paper proof.
- J. Poon and T. Dryja, “The Bitcoin Lightning Network: Scalable Off-Chain Instant Payments,” Tech. Rep., 2016.
- S. Nakamoto, “Bitcoin: A Peer-to-Peer Electronic Cash System,” Tech. Rep., 2008.
- A. Kiayias and O. S. Thyfronitis Litos, “A Composable Security Treatment of the Lightning Network,” in 2020 IEEE 33rd Computer Security Foundations Symposium (CSF), Jun. 2020, pp. 334–349, iSSN: 2374-8303.
- L. Lamport, “The temporal logic of actions,” ACM Transactions on Programming Languages and Systems, vol. 16, no. 3, pp. 872–923, May 1994. [Online]. Available: https://doi.org/10.1145/177492.177726
- C. Newcombe, T. Rath, F. Zhang, B. Munteanu, M. Brooker, and M. Deardeuff, “How Amazon web services uses formal methods,” Communications of the ACM, vol. 58, no. 4, pp. 66–73, Mar. 2015. [Online]. Available: https://dl.acm.org/doi/10.1145/2699417
- S. Resch and M. Paulitsch, “Using TLA+ in the Development of a Safety-Critical Fault-Tolerant Middleware,” in 2017 IEEE International Symposium on Software Reliability Engineering Workshops (ISSREW), Oct. 2017, pp. 146–152.
- P. Narayana, R. Chen, Y. Zhao, Y. Chen, Z. Fu, and H. Zhou, “Automatic Vulnerability Checking of IEEE 802.16 WiMAX Protocols through TLA+,” in 2006 2nd IEEE Workshop on Secure Network Protocols, Nov. 2006, pp. 44–49.
- T. Lu, S. Merz, and C. Weidenbach, “Towards Verification of the Pastry Protocol Using TLA+,” in Formal Techniques for Distributed Systems, ser. Lecture Notes in Computer Science, R. Bruni and J. Dingel, Eds. Berlin, Heidelberg: Springer, 2011, pp. 244–258.
- T. Lu, “Formal Verification of the Pastry Protocol Using TLA+,” in Dependable Software Engineering: Theories, Tools, and Applications, ser. Lecture Notes in Computer Science, X. Li, Z. Liu, and W. Yi, Eds. Cham: Springer International Publishing, 2015, pp. 284–299.
- S. Braithwaite, E. Buchman, I. Konnov, Z. Milosevic, I. Stoilkovska, J. Widder, and A. Zamfir, “Formal Specification and Model Checking of the Tendermint Blockchain Synchronization Protocol (Short Paper),” in 2nd Workshop on Formal Methods for Blockchains (FMBC 2020), ser. OpenAccess Series in Informatics (OASIcs), B. Bernardo and D. Marmsoler, Eds., vol. 84. Dagstuhl, Germany: Schloss Dagstuhl–Leibniz-Zentrum für Informatik, 2020, pp. 10:1–10:8, iSSN: 2190-6807. [Online]. Available: https://drops.dagstuhl.de/opus/volltexte/2020/13423
- Y.-M. Kim and M. Kang, “Formal Verification of SDN-Based Firewalls by Using TLA+,” IEEE Access, vol. 8, pp. 52 100–52 112, 2020, conference Name: IEEE Access.
- J.-Q. Yin, H.-B. Zhu, and Y. Fei, “Specification and Verification of the Zab Protocol with TLA+,” Journal of Computer Science and Technology, vol. 35, no. 6, pp. 1312–1323, Nov. 2020. [Online]. Available: https://doi.org/10.1007/s11390-020-0538-7
- T. Close, “Breaking state channels with TLA+,” Jun. 2020. [Online]. Available: https://blog.statechannels.org/breaking-state-channels/
- J. Kolb, J. Yang, R. H. Katz, and D. E. Culler, “Quartz: A Framework for Engineering Secure Smart Contracts,” EECS Department, University of California, Berkeley, Tech. Rep. UCB/EECS-2020-178, Aug. 2020. [Online]. Available: http://www2.eecs.berkeley.edu/Pubs/TechRpts/2020/EECS-2020-178.html
- Z. Nehaï, F. Bobot, S. Tucci-Piergiovanni, C. Delporte-Gallet, and H. Fauconnier, “A TLA+ Formal Proof of a Cross-Chain Swap,” in Proceedings of the 23rd International Conference on Distributed Computing and Networking, ser. ICDCN ’22. New York, NY, USA: Association for Computing Machinery, Jan. 2022, pp. 148–159. [Online]. Available: https://dl.acm.org/doi/10.1145/3491003.3491006
- R. Canetti, “Universally composable security: a new paradigm for cryptographic protocols,” in Proceedings 42nd IEEE Symposium on Foundations of Computer Science, Oct. 2001, pp. 136–145, iSSN: 1552-5244.
- M. Grundmann and H. Hartenstein, “Verifying Payment Channels with TLA+,” in 2022 IEEE International Conference on Blockchain and Cryptocurrency (ICBC), May 2022, pp. 1–3.
- A. Kiayias and O. S. Thyfronitis Litos, “A Composable Security Treatment of the Lightning Network,” 2019, report Number: 778. [Online]. Available: https://eprint.iacr.org/2019/778
Paper Prompts
Sign up for free to create and run prompts on this paper using GPT-5.
Top Community Prompts
Collections
Sign up for free to add this paper to one or more collections.