Efficient and Universal Merkle Tree Inclusion Proofs via OR Aggregation
Abstract
:1. Introduction
- For a given set X of leaves in a Merkle tree, create a universal proof that allows for efficient verification of whether an arbitrary pair (b, h) belongs to X, where h is the hash value of b, without the need to provide or process all leaves from X during each verification.
- We adapt and extend the concept of OR aggregation, which was previously discussed in the context of Sigma protocols, to create a recursive aggregation scheme specifically designed for Merkle tree proofs.
- We provide a detailed description of the process for generating a universal, compact proof for Merkle tree inclusion using recursive OR aggregation.
- We present a comparative analysis that demonstrates the advantages of our approach in terms of proof size, verification data, and universality, particularly in contrast to traditional AND aggregation methods.
- We discuss the practical implications of our method for blockchain applications, including potential optimizations for smart contract execution and improvements in the overall system efficiency.
2. Background and Literature Review
2.1. Zero-Knowledge Proofs
- Completeness: If the statement is true, an honest prover should be able to convince an honest verifier of its validity.
- Soundness: If the statement is false, no prover (even a dishonest one) should be able to convince an honest verifier that it is true, except with a negligible probability.
- Zero-knowledge: The verifier should not learn any information from the proof except for the validity of the statement.
2.2. Merkle Trees
2.3. Proof Aggregation Techniques
3. Enhanced Aggregation Logic
3.1. Foundations: Sigma Protocols and OR Composition
- 1.
- → : the prover’s first move, which generates the initial message .
- 2.
- → : the verifier’s challenge .
- 3.
- → : the prover’s response to the challenge.
- 4.
- → : the verifier’s final decision to accept (1) or reject (0).
- 1.
- Completeness: an honest prover can always convince an honest verifier.
- 2.
- Special soundness: given two accepting transcripts and for , one can efficiently extract a witness .
- 3.
- Special honest-verifier zero knowledge: there exists a simulator that can produce transcripts indistinguishable from real protocol executions.
3.2. Motivation for an Improved Universal Proof
- —public statement (highlighted in green in Figure 3);
- —secret witness (highlighted in red in Figure 3);
- —concatenation function (combining vectors).
3.3. OR Aggregation for Merkle Tree Proofs
3.4. Generating a Universal Proof for Merkle Tree Inclusion
- 1.
- Generate proofs for each leaf: For each leaf node in the Merkle tree, generate a zero-knowledge proof that attests to the correctness of the leaf hash . This can be done using a suitable zero-knowledge proof system, such as zk-SNARKs or zk-STARKs.
- 2.
- Aggregate proofs using OR logic: Starting from the leaves, recursively aggregate the proofs of adjacent nodes using OR logic, as described in Section 4.2. At each level, the proofs of sibling nodes are combined to form a proof for their parent node (highlighted in yellow in Figure 5). This process is repeated until a single proof is obtained for the root of the tree.
- 3.
- Output the universal proof: The aggregated proof for the root of the Merkle tree, , serves as the universal proof of inclusion. This proof has the property that it can be validated by providing any one of the valid leaf hashes as the input:
3.5. Comparison with Existing Approaches
4. Discussion and Analysis
4.1. Comparative Analysis of Merkle Tree Proof Techniques
- Standard Merkle proof: while efficient for single-leaf verification, it lacks universality and scales logarithmically with tree size.
- AND aggregation: offers a universal proof but requires all leaf hashes for verification, leading to a high data overhead.
- Maru project [36]: achieves constant-size proofs and verification data but lacks universality.
- Our OR aggregation: combines the advantages of constant-size proofs, minimal verification data, and universality.
4.2. Practical Implications for Blockchain Systems
- Improved throughput: By reducing the verification complexity to O(1), our approach allows for significantly higher transaction throughput in blockchain networks. This is particularly important for large-scale, high-volume applications.
- Reduced storage requirements: the compact nature of our universal proofs means that less storage is required for maintaining proof data, potentially leading to reduced costs for node operators.
- Enhanced light client functionality: our method enables more efficient light client implementations, as clients can verify the inclusion of any leaf in the Merkle tree with minimal computational and data transfer overhead.
- Flexible verification: the ability to verify the inclusion of any leaf using a single universal proof provides greater flexibility in how blockchain data can be accessed and verified.
4.3. Extending the Technique to New Applications
- Partial group verification: in scenarios where a condition must be met by at least one participant from a group, OR aggregation can be used to efficiently verify this without checking each proof individually.
- Complete group verification: for cases requiring all participants to satisfy a condition, AND aggregation can be employed to create a single, verifiable proof of complete compliance.
- Nested conditions: complex scenarios involving combinations of conditions (e.g., “all participants from group A OR at least one from group B”) can be represented by nesting AND and OR aggregations.
4.4. Potential Limitations and Future Work
- Proof generation overhead: Although verification is highly efficient, the initial proof generation process may be more computationally intensive than traditional methods. Future work could focus on optimizing this process.
- Security considerations: As with any new cryptographic technique, thorough security analysis is crucial. Future studies should focus on formal security proofs and potential attack vectors.
- Integration with existing systems: further research is needed to explore the best practices for integrating our approach with existing blockchain protocols and infrastructure.
- Extension to other data structures: while our focus has been on Merkle trees, future work could explore the application of similar OR aggregation techniques to other cryptographic data structures used in blockchain systems.
- Theoretical foundations: further research could explore the theoretical underpinnings of our approach, potentially leading to new insights in the field of zero-knowledge proofs and their applications.
5. Conclusions
Author Contributions
Funding
Data Availability Statement
Conflicts of Interest
References
- Bowe, S.; Gabizon, A.; Green, M.D. A Multi-Party Protocol for Constructing the Public Parameters of the Pinocchio Zk-SNARK. In Proceedings of the Financial Cryptography and Data Security: FC 2018 International Workshops, BITCOIN, VOTING, and WTSC, Nieuwpoort, Curaçao, 26 February–2 March 2018. [Google Scholar]
- Ben-Sasson, E.; Chiesa, A.; Tromer, E.; Virza, M. Succinct Non-Interactive Zero Knowledge for a von Neumann Architecture. In Proceedings of the 23rd USENIX Security Symposium, San Diego, CA, USA, 20–22 August 2014. [Google Scholar]
- Goldwasser, S.; Micali, S.; Rackoff, C. The Knowledge Complexity of Interactive Proof-Systems. In Proceedings of the Seventeenth Annual ACM Symposium on Theory of Computing, Providence, RI, USA, 6–8 May 1985; pp. 291–304. [Google Scholar]
- Zhou, L.; Diro, A.; Saini, A.; Kaisar, S.; Hiep, P.C. Leveraging Zero Knowledge Proofs for Blockchain-Based Identity Sharing: A Survey of Advancements, Challenges and Opportunities. J. Inf. Secur. Appl. 2024, 80, 103678. [Google Scholar] [CrossRef]
- Shahrouz, J.K.; Analoui, M. An Anonymous Authentication Scheme with Conditional Privacy-Preserving for Vehicular Ad Hoc Networks Based on Zero-Knowledge Proof and Blockchain. Ad Hoc Netw. 2024, 154, 103349. [Google Scholar] [CrossRef]
- Ren, Z.; Yan, E.; Chen, T.; Yu, Y. Blockchain-Based CP-ABE Data Sharing and Privacy-Preserving Scheme Using Distributed KMS and Zero-Knowledge Proof. J. King Saud Univ.-Comput. Inf. Sci. 2024, 36, 101969. [Google Scholar] [CrossRef]
- Zheng, H.; You, L.; Hu, G. A Novel Insurance Claim Blockchain Scheme Based on Zero-Knowledge Proof Technology. Comput. Commun. 2022, 195, 207–216. [Google Scholar] [CrossRef]
- Ethereum Ethereum Yellow Paper. 2023. Available online: https://github.com/ethereum/yellowpaper (accessed on 2 July 2024).
- Mitra, D.; Tauz, L.; Dolecek, L. Graph Coded Merkle Tree: Mitigating Data Availability Attacks in Blockchain Systems Using Informed Design of Polar Factor Graphs. IEEE J. Sel. Areas Inf. Theory 2023, 4, 434–452. [Google Scholar] [CrossRef]
- Mitra, D.; Tauz, L.; Dolecek, L. Polar Coded Merkle Tree: Improved Detection of Data Availability Attacks in Blockchain Systems. In Proceedings of the 2022 IEEE International Symposium on Information Theory (ISIT), Espoo, Finland, 26 June–1 July 2022; pp. 2583–2588. [Google Scholar]
- Otte, P.; de Vos, M.; Pouwelse, J. TrustChain: A Sybil-Resistant Scalable Blockchain. Future Gener. Comput. Syst. 2020, 107, 770–780. [Google Scholar] [CrossRef]
- Nasir, M.H.; Arshad, J.; Khan, M.M.; Fatima, M.; Salah, K.; Jayaraman, R. Scalable Blockchains—A Systematic Review. Future Gener. Comput. Syst. 2022, 126, 136–162. [Google Scholar] [CrossRef]
- Bin Hasan, K.M.; Sajid, M.; Lapina, M.A.; Shahid, M.; Kotecha, K. Blockchain Technology Meets 6 G Wireless Networks: A Systematic Survey. Alex. Eng. J. 2024, 92, 199–220. [Google Scholar] [CrossRef]
- Singh, R.; Dwivedi, A.D.; Mukkamala, R.R.; Alnumay, W.S. Privacy-Preserving Ledger for Blockchain and Internet of Things-Enabled Cyber-Physical Systems. Comput. Electr. Eng. 2022, 103, 108290. [Google Scholar] [CrossRef]
- Ràfols, C.; Zacharakis, A. Folding Schemes with Selective Verification. In Proceedings of the 8th International Conference on Cryptology and Information Security in Latin America, Quito, Ecuador, 3–6 October 2023. [Google Scholar]
- Ciampi, M.; Persiano, G.; Scafuro, A.; Siniscalchi, L.; Visconti, I. Improved OR-Composition of Sigma-Protocols. In Proceedings of the Theory of Cryptography: 13th International Conference, TCC 2016-A, Tel Aviv, Israel, 10–13 January 2016; Kushilevitz, E., Malkin, T., Eds.; Springer: Berlin/Heidelberg, Germany, 2016; pp. 112–141. [Google Scholar]
- Nitulescu, A. A Gentle Introduction to SNARKs. 2019. Available online: https://api.semanticscholar.org/CorpusID:209520686 (accessed on 2 July 2024).
- Ramos Fernández, R. Evaluation of Trust Service and Software Product Regimes for Zero-Knowledge Proof Development under eIDAS 2.0. Comput. Law Secur. Rev. 2024, 53, 105968. [Google Scholar] [CrossRef]
- Wen, X.-J.; Chen, Y.-Z.; Fan, X.-C.; Zhang, W.; Yi, Z.-Z.; Fang, J.-B. Blockchain Consensus Mechanism Based on Quantum Zero-Knowledge Proof. Opt. Laser Technol. 2022, 147, 107693. [Google Scholar] [CrossRef]
- Boneh, D.; ZK Whiteboard Sessions. Introductory Modules with Dan Boneh. ZK Hack. Available online: https://zkhack.dev/whiteboard/ (accessed on 2 July 2024).
- Bowe, S.; Gabizon, A.; Miers, I. Scalable Multi-Party Computation for Zk-SNARK Parameters in the Random Beacon Model. Cryptol. ePrint Arch. 2017; preprint. [Google Scholar]
- Ashur, T.; Dhooghe, S. MARVELlous: A STARK-Friendly Family of Cryptographic Primitives. Cryptol. ePrint Arch. 2018; preprint. [Google Scholar]
- Boneh, D.; Bünz, B.; Fisch, B. Batching Techniques for Accumulators with Applications to IOPs and Stateless Blockchains. In Proceedings of the Advances in Cryptology–CRYPTO 2019: 39th Annual International Cryptology Conference, Santa Barbara, CA, USA, 18–22 August 2019; Boldyreva, A., Micciancio, D., Eds.; Springer International Publishing: Cham, Swizterland, 2019; pp. 561–586. [Google Scholar]
- Garreta, A.; Hovhanissyan, H.; Jivanyan, A.; Manzur, I.; Villalobos, I.; Zając, M. On Amortization Techniques for FRI-Based SNARKs. IACR Cryptol. ePrint Arch. 2024; preprint. [Google Scholar]
- Huang, Y.; Zheng, X.; Zhu, Y. Optimized CPU–GPU Collaborative Acceleration of Zero-Knowledge Proof for Confidential Transactions. J. Syst. Archit. 2023, 135, 102807. [Google Scholar] [CrossRef]
- Emami, A.; Yajam, H.; Akhaee, M.A.; Asghari, R. A Scalable Decentralized Privacy-Preserving e-Voting System Based on Zero-Knowledge off-Chain Computations. J. Inf. Secur. Appl. 2023, 79, 103645. [Google Scholar] [CrossRef]
- Yao, S.; Zhang, D. An Anonymous Verifiable Random Function with Unbiasability and Constant Size Proof. J. Inf. Secur. Appl. 2024, 83, 103778. [Google Scholar] [CrossRef]
- Merkle, R.C. Method of Providing Digital Signatures. 1982. Available online: https://patents.google.com/patent/US4309569A/en (accessed on 2 July 2024).
- Merkle, R.C. A Digital Signature Based on a Conventional Encryption Function. In Proceedings of the Advances in Cryptology—CRYPTO’87, Conference on the Theory and Application of Cryptographic Techniques, Santa Barbara, CA, USA, 16–20 August 1987; Pomerance, C., Ed.; Springer: Berlin, Heidelberg, 1988; pp. 369–378. [Google Scholar]
- Kuznetsov, O.; Rusnak, A.; Yezhov, A.; Kuznetsova, K.; Kanonik, D.; Domin, O. Merkle Trees in Blockchain: A Study of Collision Probability and Security Implications. Internet Things 2024, 26, 101193. [Google Scholar] [CrossRef]
- George, J.T. Bitcoin. In Introducing Blockchain Applications: Understand and Develop Blockchain Applications Through Distributed Systems; George, J.T., Ed.; Apress: Berkeley, CA, USA, 2022; pp. 9–54. ISBN 978-1-4842-7480-4. [Google Scholar]
- ZKP MOOC Lecture 10: Recursive SNARKs. 2023. Available online: https://www.youtube.com/watch?v=0LW-qeVe6QI (accessed on 2 July 2024).
- StarkWare Recursive STARKs. StarkWare. 2022. Available online: https://medium.com/starkware/recursive-starks-78f8dd401025 (accessed on 2 July 2024).
- Bellare, M.; Garay, J.A.; Rabin, T. Fast Batch Verification for Modular Exponentiation and Digital Signatures. In Proceedings of the Advances in Cryptology—EUROCRYPT’98, International Conference on the Theory and Applications of Cryptographic Techniques, Espoo, Finland, 31 May–4 June 1998; Nyberg, K., Ed.; Springer: Berlin/Heidelberg, Germany, 1998; pp. 236–250. [Google Scholar]
- Waters, B.; Wu, D.J. Batch Arguments for NP and More from Standard Bilinear Group Assumptions. In Proceedings of the Advances in Cryptology—CRYPTO 2022, Annual International Cryptology Conference, Santa Barbara, CA, USA, 15–18 August 2022. [Google Scholar]
- Kuznetsov, O.; Rusnak, A.; Yezhov, A.; Kanonik, D.; Kuznetsova, K.; Karashchuk, S. Enhanced Security and Efficiency in Blockchain with Aggregated Zero-Knowledge Proof Mechanisms. IEEE Access 2024, 12, 49228–49248. [Google Scholar] [CrossRef]
- Cramer, R.; Damgård, I.; Schoenmakers, B. Proofs of Partial Knowledge and Simplified Design of Witness Hiding Protocols. In Proceedings of the Advances in Cryptology—CRYPTO’94, Annual International Cryptology Conference, Santa Barbara, CA, USA, 21–25 August 1994; Desmedt, Y.G., Ed.; Springer: Berlin/Heidelberg, Germany, 1994; pp. 174–187. [Google Scholar]
Metric | Standard Merkle Proof | AND Aggregation | Maru Project [36] | Our OR Aggregation |
---|---|---|---|---|
Proof size | O(log n) | O(1) | O(1) | O(1) |
Verification data | O(log n) | O(n) | O(1) | O(1) |
Universality | No | Yes | No | Yes |
Verification complexity | O(log n) | O(1) | O(1) | O(1) |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2024 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Kuznetsov, O.; Rusnak, A.; Yezhov, A.; Kanonik, D.; Kuznetsova, K.; Domin, O. Efficient and Universal Merkle Tree Inclusion Proofs via OR Aggregation. Cryptography 2024, 8, 28. https://doi.org/10.3390/cryptography8030028
Kuznetsov O, Rusnak A, Yezhov A, Kanonik D, Kuznetsova K, Domin O. Efficient and Universal Merkle Tree Inclusion Proofs via OR Aggregation. Cryptography. 2024; 8(3):28. https://doi.org/10.3390/cryptography8030028
Chicago/Turabian StyleKuznetsov, Oleksandr, Alex Rusnak, Anton Yezhov, Dzianis Kanonik, Kateryna Kuznetsova, and Oleksandr Domin. 2024. "Efficient and Universal Merkle Tree Inclusion Proofs via OR Aggregation" Cryptography 8, no. 3: 28. https://doi.org/10.3390/cryptography8030028
APA StyleKuznetsov, O., Rusnak, A., Yezhov, A., Kanonik, D., Kuznetsova, K., & Domin, O. (2024). Efficient and Universal Merkle Tree Inclusion Proofs via OR Aggregation. Cryptography, 8(3), 28. https://doi.org/10.3390/cryptography8030028