baudetph
Posts: 1
Joined: Wed Feb 03, 2016 8:22 am

How do miners access to transaction referenced in the inputs of new transactions

Wed Feb 03, 2016 8:49 am

i don't understand how miners prevent easily an output tx from double spent. I understand that when a transaction is broadcasted to the network, miners will try to add it to a block. For that they will check that signature script of each input match with pubkey script of corresponding output of the corresponding previous transaction. My question is :
- how do miners get easily the previous tx from which bitcoins are to be spent knowing only its identifier. Tx identifier doesn't tell in what block this transaction is mined, and block headers don't provide this information meaning you have to look out the whole blocks.
- Does each miner maintain its own ledger of transactions (tx id, block in which it is included, spent ("yes" or "no") and if "yes" in what block and transaction) ?

User avatar
zju
Nickel Bitcoiner
Nickel Bitcoiner
Posts: 62
Joined: Fri Oct 02, 2015 5:27 am

Re: How do miners access to transaction referenced in the inputs of new transactions

Mon Jun 06, 2016 9:02 pm

Full nodes maintain a list of all unspent transaction outputs (aka "UTXO") and validate new transactions against that list.

Return to “Bitcoin Core”

Who is online

Users browsing this forum: No registered users and 4 guests