Bitcoin Forum
September 12, 2026, 03:11:27 PM *
News: Latest Bitcoin Core release: 31.1 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Can a Bitcoin node build a partial UTXO set from recent N blocks?  (Read 55 times)
cao123456 (OP)
Newbie
*
Offline

Activity: 1
Merit: 0


View Profile
Today at 02:39:17 AM
 #1

I am investigating whether a storage-constrained Bitcoin node could retain only the most recent (N) blocks, construct a partial UTXO set from those blocks, and use that partial UTXO set to independently validate newly received transactions.

The basic idea would be:

recent (N) blocks → construct a partial UTXO set → validate a new transaction locally if all of its input UTXOs are available in that partial set.

However, I see a potential bootstrap problem.

Suppose the node starts with only the most recent (N) blocks. Some transactions in the earliest retained blocks may spend outputs created before the retained window. Without the earlier UTXO state, the node cannot fully validate those inputs.

If the node therefore cannot fully validate those blocks, can it safely treat the outputs created by those blocks as valid UTXOs and progressively construct a partial UTXO set from them?

More generally:

Is it technically feasible for a Bitcoin node to construct a trustworthy partial UTXO set using only the most recent (N) blocks, without first obtaining a validated UTXO state at the beginning of the retained window?

If all inputs of a newly received transaction are present in such a partial UTXO set, would that be sufficient for the node to independently validate that transaction, or would the incomplete validation history of the partial UTXO set prevent this?

How is this different from the way a Bitcoin wallet maintains information about its own UTXOs? A wallet does not maintain the complete global UTXO set, so what provides the trust basis for the wallet's view of its own unspent outputs?

If this approach is technically possible, why is recent-block-based partial UTXO construction not commonly used by lightweight Bitcoin nodes today? What are the main technical or security limitations?

I am particularly interested in the trust/validation issue rather than merely the storage savings.
LoyceV
Legendary
*
Offline

Activity: 4158
Merit: 22662


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
Today at 05:40:57 AM
 #2

Is it technically feasible for a Bitcoin node to construct a trustworthy partial UTXO set using only the most recent (N) blocks, without first obtaining a validated UTXO state at the beginning of the retained window?
No.

Quote
If all inputs of a newly received transaction are present in such a partial UTXO set, would that be sufficient for the node to independently validate that transaction
No. Someone could create Bitcoin out of thin air and you would just think the UTXO wasn't in your partial UTXO set.

¡uʍop ǝpᴉsdn pɐǝɥ ɹnoʎ ɥʇᴉʍ ʎuunɟ ʞool no⅄
TheButterZone
Legendary
*
Offline

Activity: 3262
Merit: 1130


RIP Mommy


View Profile WWW
Today at 07:12:20 AM
Merited by nutildah (4)
 #3

Quote from: Google AI Mode
This exact dilemma is why Floresta and Mandacaru exist. They solve the exact problem you are trying to solve (running a node on a storage-constrained device) but without compromising the validation history.
Instead of guessing or truncating the UTXO set based on a time window, Floresta uses Utreexo, a dynamic hash-based accumulator.

* The global UTXO set (millions of entries, tens of gigabytes) is compressed into a compact set of roots (under 1 Kilobyte).
* When a Floresta node receives a new transaction, the sending peer attaches a cryptographic proof showing that the UTXOs being spent exist inside those tiny roots.
* This allows a mobile phone running Mandacaru to independently validate transactions from Genesis onward without actually holding the gigabytes of data that a traditional node requires.

Furthermore, projects like Mandacaru utilize assumeutreexo (similar to Core's assumevalid). It allows the node to bootstrap instantly by hardcoding a cryptographically signed snapshot of the Utreexo accumulator roots at a specific recent block height, bypassing the initial history securely while maintaining full validation going forward.

Mandacaru discussion here: https://bitcointalk.org/index.php?topic=5579479.0

nc50lc
Legendary
*
Offline

Activity: 3262
Merit: 9140


Self-proclaimed Genius


View Profile
Today at 07:32:52 AM
Merited by LoyceV (6), ABCbits (2)
 #4

How is this different from the way a Bitcoin wallet maintains information about its own UTXOs? A wallet does not maintain the complete global UTXO set, so what provides the trust basis for the wallet's view of its own unspent outputs?
No UTXO set is kept locally by those lightweight wallets because they can't verify alone without connecting to a full node.

For comparison;
Compared to SPV wallets?
It's totally different because those still relies on full nodes to verify while only keeping the block headers to see if those nodes are providing it the correct data.

Or compared to the new clients that utilizes "Compact Block Filters"?
BIP157 Specs should explain it better: github.com/bitcoin/bips/blob/master/bip-0157.mediawiki#specification

ABCbits
Legendary
*
Offline

Activity: 3724
Merit: 10368



View Profile
Today at 08:34:35 AM
 #5

However, I see a potential bootstrap problem.

Suppose the node starts with only the most recent (N) blocks. Some transactions in the earliest retained blocks may spend outputs created before the retained window. Without the earlier UTXO state, the node cannot fully validate those inputs.

There's bigger problem. If new/fresh node literally only download most recent N blocks, how can it verify those block actually part of longest chain and input of each TX isn't created from UTXO that never exist or already spend?

Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!