Research

Verification of Account Balances in the Bitcoin System Using Merkle Trees

Vipul Goyal (Professor, Carnegie Mellon University)

This study investigates the intricate structure of the Bitcoin protocol, focusing on block architecture, node classification, and transaction validation mechanisms. The primary challenge addressed is the difficulty light nodes face in verifying account balances using current Bitcoin practices. The research proposes an innovative solution that incorporates the Merkle tree root of the UTXO set into the unused portion of the coinbase transaction input field. This integration allows light nodes to leverage Merkle proofs for verifying account balances, enhancing accuracy and trust within the network. The proposed changes adhere to soft fork standards, encouraging node upgrades while preserving network integrity.

Introduction

Bitcoin revolutionized digital finance with its decentralized system grounded in cryptographic principles. Despite the security and transparency provided by its protocol, Bitcoin faces challenges, particularly in node-light transaction validation. This study examines the block structure, node types, and validation methods within the Bitcoin protocol to address the issue of light nodes being unable to independently verify account balances. An innovative solution is proposed to bridge the trust gap while maintaining decentralization.

Previous Work

To develop the proposed solution, a comprehensive review of the Bitcoin protocol was conducted. Key findings include:

Block Structure: Bitcoin blocks consist of a header and body. The header contains crucial data, including the Merkle root, ensuring transaction integrity. The body, significantly larger, records transaction information.

Node Classification: Bitcoin nodes are categorized as full or light nodes. Full nodes store the entire blockchain and perform comprehensive verification tasks, whereas light nodes store only block headers and partial transaction data, utilizing Merkle trees for transaction verification.

Merkle Trees and Proofs: Merkle trees store transaction information in a hierarchical hash structure, enabling light nodes to verify transactions using Merkle proofs provided by full nodes.

UTXO Set: The UTXO set represents unspent transaction outputs, maintained by full nodes and essential for verifying account balances.

Approach

The proposed solution involves using the input field of coinbase transactions to store the Merkle root of the UTXO set. This allows light nodes to verify account balances through a two-layer Merkle proof process. The inner layer verifies the UTXO Merkle tree, while the outer layer verifies the entire block's Merkle tree.

Innovation: By organizing the UTXO set into a Merkle tree and storing its root in the coinbase transaction's input, light nodes can independently verify their account balances using Merkle proofs.

Implementation: Light nodes request a Merkle proof from full nodes, including transaction details and hash values. The light node calculates the Merkle root and compares it with the stored root, ensuring transaction validity.

Protocol Enhancement: The proposed changes constitute a soft fork, as they modify the coinbase transaction input field. This incentivizes nodes to upgrade their protocols, ensuring widespread adoption.

Conclusion

The study proposes utilizing the unused portion of the coinbase transaction input field to include the UTXO Merkle tree root. This enables light nodes to verify account balances using Merkle proofs, enhancing trust and accuracy in the Bitcoin network. The protocol changes align with soft fork standards, incentivizing node upgrades and maintaining network integrity.

Keywords

Bitcoin, Merkle trees, light nodes, UTXO, transaction verification, soft fork, blockchain security