<p>Mastercoin adds a layer on top of Bitcoin.<br/>
It uses small transaction in the Bitcoin blockchain to transfer Mastercoins.<br/>
Thus the Bitcoin blockchain is used to avoid double spending the same way it is used for Bitcoins.</p>

CC BY-SA 3.0
2013-12-29T06:24:59.867Z
2013-12-29T06:24:59.867Z
torusJKL
<p>The answer is double-layered:</p>

<ol>
<li>Mastercoin uses Bitcoin for timestamping. It's impossible to revert the transaction at the Bitcoin level without doing a Bitcoin double spend (super costly).</li>
<li>Mastercoin clients track the state of the system including how much is stored at each address. If a client double spends by sending two contradicting Mastercoin transactions, the second one will be discarded as an invalid spend by any client that parses the transaction stream.</li>
</ol>

CC BY-SA 3.0
2013-12-30T09:46:26.320Z
Thanks Ron. So after posting that question I realized that in fact, also in bitcoin the blockchain is not there to avoid double spend directly. The block-chain is there to ensure a consistent history. Bitcoin clients protect from double spend by checking new transactions' validity against the history. Thus, bitcoin, and anything using bitcoin as a time stamping device, are equally protected from double spend (well, equally as far as the block-chain is concerned, of course each client needs to do a good job in transaction validation). Does that sound right?
Assaf Shomer
CC BY-SA 3.0
2013-12-30T10:19:41.077Z
Let me elaborate a little on my previous comment. The block-chain achieves a consistent (single) and durable (hard to change) history. Double spend can occur in two ways. 1 - Send two conflicting transactions: This is dealt with in the client. 2 - Change history: This is taken care of by the block-chain.
Assaf Shomer
CC BY-SA 3.0
2014-01-01T23:24:29.763Z
@AssafShomer - yeah, you got that nailed.
ripper234
CC BY-SA 3.0
2013-12-29T15:46:48.717Z
2013-12-29T15:46:48.717Z
ripper234
<p>Bitcoin's main innovation is the blockchain, responsible for making sure that the same bitcoin cannot be spent twice.</p>

<p>Mastercoin rides on top of bitcoin, but does not have it's own blockchain.</p>

<p>How does Mastercoin avoid double-spend attacks?</p>

<omni>
How does Mastercoin avoid double-spend attacks without it's own blockchain?
Assaf Shomer
# How does Mastercoin avoid double-spend attacks without it's own blockchain?

(Asked by: username_0 on 2013-12-28)

Bitcoin's main innovation is the blockchain, responsible for making sure that the same bitcoin cannot be spent twice.

Mastercoin rides on top of bitcoin, but does not have it's own blockchain.

How does Mastercoin avoid double-spend attacks?

**Tags:** omni


---

## 2 answers

### Answer by username_2 on 2013-12-29. Score: 10 | Accepted answer

The answer is double-layered:

1. Mastercoin uses Bitcoin for timestamping. It's impossible to revert the transaction at the Bitcoin level without doing a Bitcoin double spend (super costly).
2. Mastercoin clients track the state of the system including how much is stored at each address. If a client double spends by sending two contradicting Mastercoin transactions, the second one will be discarded as an invalid spend by any client that parses the transaction stream.

> **Comments:**
> **username_0**: Thanks Ron. So after posting that question I realized that in fact, also in bitcoin the blockchain is not there to avoid double spend directly. The block-chain is there to ensure a consistent history. Bitcoin clients protect from double spend by checking new transactions' validity against the history. Thus, bitcoin, and anything using bitcoin as a time stamping device, are equally protected from double spend (well, equally as far as the block-chain is concerned, of course each client needs to do a good job in transaction validation). Does that sound right?  
> **username_0**: Let me elaborate a little on my previous comment. The block-chain achieves a consistent (single) and durable (hard to change) history. Double spend can occur in two ways. 1 - Send two conflicting transactions: This is dealt with in the client. 2 - Change history: This is taken care of by the block-chain.  
> **username_2**: @username_0 - yeah, you got that nailed.  

---

### Answer by username_1 on 2013-12-29. Score: 4

Mastercoin adds a layer on top of Bitcoin.  
It uses small transaction in the Bitcoin blockchain to transfer Mastercoins.  
Thus the Bitcoin blockchain is used to avoid double spending the same way it is used for Bitcoins.


---

