What does a double spend look like?

6

What does a double spend look like? Can anyone link to an example on blockchain.info?

Will invalid half of the double spend simply remain at 0-confirmations, or might it ever reach 1 or 2? Will the standard bitcoind client provide any type of flag for known invalid transactions?

Shea

Posted 2012-05-29T17:05:00.530

Reputation: 163

Answers

6

You won't be able to see a double-spend in the block chain, because it is invalid. You will see one of the transactions included in the chain though. Blockchain.info has a page showing the most recent double-spends.

Double spend is just two (or more) transactions claiming the same input, so they will look like an ordinary pair of transaction. One of them will get included in a block, the other will eventually be forgotten by the network. A conflicting transaction to the one included in a valid block can never become a part of another block (at least until the first block will become invalidated by a 51% attack).

The standard client will not flag any invalid transactions, but it will reject any transaction that conflicts with a known transaction. It will, however, accept a transaction that is a part of a block, even if it conflicts with a 0-confirmation transaction that you know of.

ThePiachu

Posted 2012-05-29T17:05:00.530

Reputation: 41 594

So lets say my bitcoin client receives a 0-confirmation transaction. It then accepts ten blocks which have a conflicting transaction. Does the original 0-confirmation transaction remain listed in my client's transactions, or does it just disappear? What if the first transaction had 1 confirmation instead of 0?Shea 2012-05-29T17:34:36.297

The transaction will remain in your client, but other clients will start forgetting about it. It will have 0-confirmations. If the first transaction has 1 confirmation, it means it was a part of a block. Should a conflicting block be mined, it will be reverted to 0-confirmations.ThePiachu 2012-05-29T20:18:01.290

When he says "an example on blockchain" perhaps he means on blockchain.info - I've seen it claim transactions were potential double spends before.Chris Moore 2012-05-29T22:01:23.580

Ah yes sorry, I did mean blockchain.info. However, ThePiachu has explained it well without it.Shea 2012-05-30T13:49:56.450