<p>What you are describing is a textbook example of a 51% attack. Bitcoin protocol is designed to accept the chain that has the most proof of work (most often this is same as the longest chain). If a miner needs to change block 90, he will have to recalculate hashes starting from block 90-100. To make his attack successful, the miner will have to mine blocks faster than the rest of the network so that he can broadcast the longest chain which then gets accepted by the network. So, probabilistically this would mean the miner should be in control of >50% of the total hashing power, so that he can mine blocks faster than rest of the network combined.</p>

CC BY-SA 4.0
2019-04-08T11:13:06.813Z
Thanks for the answer. But how do other miners figure out that he is cheating? Do they have a look into the hashes of the blocks and compare them? And what happens to a cheating miner? Does he get excluded from the network?
Michael
CC BY-SA 4.0
2019-04-08T11:16:09.227Z
If the miner has created valid blocks following all the rules of the bitcoin protocol, then the chain he has created is valid. Nodes accept chains that has the most proof of work. If the malicious miner is able to race the network into creating the longest chain then yes, that is the truthful chain
Ugam Kamat
CC BY-SA 4.0
2019-04-08T09:46:09.153Z
2019-04-08T11:14:22.507Z
2019-04-08T11:14:22.507Z
Ugam Kamat
<p>Let's assume we have 100 blocks. One miner x has the intention to manipulate block 90. So he has to recalculate the hash for block 90. Following he also has to recalculate the hashes for block 91-100. 
Correct me, if I'm talking non-sense here.</p>

<p>So how do all the other miners figure out that miner x is cheating? And what happens to miner x, if he gets caught? </p>

<blockchain><security>
How does the Blockchain detect a cheater, who manipulates the blockchain?
Michael
# How does the Blockchain detect a cheater, who manipulates the blockchain?

(Asked by: username_0 on 2019-04-08)

Let's assume we have 100 blocks. One miner x has the intention to manipulate block 90. So he has to recalculate the hash for block 90. Following he also has to recalculate the hashes for block 91-100.
Correct me, if I'm talking non-sense here.

So how do all the other miners figure out that miner x is cheating? And what happens to miner x, if he gets caught?

**Tags:** blockchain, security


---

## 1 answers

### Answer by username_1 on 2019-04-08. Score: 1

What you are describing is a textbook example of a 51% attack. Bitcoin protocol is designed to accept the chain that has the most proof of work (most often this is same as the longest chain). If a miner needs to change block 90, he will have to recalculate hashes starting from block 90-100. To make his attack successful, the miner will have to mine blocks faster than the rest of the network so that he can broadcast the longest chain which then gets accepted by the network. So, probabilistically this would mean the miner should be in control of >50% of the total hashing power, so that he can mine blocks faster than rest of the network combined.

> **Comments:**
> **username_0**: Thanks for the answer. But how do other miners figure out that he is cheating? Do they have a look into the hashes of the blocks and compare them? And what happens to a cheating miner? Does he get excluded from the network?  
> **username_1**: If the miner has created valid blocks following all the rules of the bitcoin protocol, then the chain he has created is valid. Nodes accept chains that has the most proof of work. If the malicious miner is able to race the network into creating the longest chain then yes, that is the truthful chain  

---

