Post
Topic
Board Mining
Re: Confirming transactions?
by
Xyver
on 04/11/2013, 07:17:35 UTC
You've got part of it right.  A block is like a box that's been filled with transactions and then filed into the blockchain.  However, it's more of the following:


1) There are hundreds of transactions floating in the network that are not yet included in any block.
2) Miners group those unconfirmed transactions into a *potential* block, and start trying to come up with a hash that will meet the current network difficulty for this potential block they've assembled.  They pick transactions based on priority, which is a mixture of the age of a transactions inputs, the size of the inputs/outputs, and the fees attached to the transaction.
3) If a miner creates a successful hash for their potential block, they broadcast the block to the network that they now have a new block properly added to the blockchain.  This gives transactions their first confirmation.  As future blocks are added to the chain based off this one, they gain an extra confirmation.

3a)  If two competing miners come up with a block solution at the same time, it's possible your transaction *loses* its confirmation.  If the competing block found at the same time (roughly) does not include it, and the following block on the network uses this competing block, your transaction will lose its confirmation and end up floating across the network again waiting for a miner to pick it up.

Right.  So do the miners confirm the transactions before they put them in the box?  Or are they confirmed when the block is solved.  I know you mean that the blocks get multiple confirmations the deeper they are in the chain, but when are they checked for double spends or false coins?  Is that when the miners put them in the block?