Last Updated on February 17, 2022
Proof Of Work And The 51% Attack
- The 51% attack is the one known pitfall of the blockchain Proof of Work mining method.
- Miners are blockchain building nodes.
- Miners get reward for building blocks the fastest.
- More mining power (nodes, or computers) means you have more chance to win the reward.
- This has resulted is massive investment for mining machines, which can be dominated by only a few groups (companies.)
- The Proof of Work consensus needs a majority of nodes to agree that a new block, and the chain is valid. The nodes are called miners.
- Miners are competing against each other by generating a code (known as a hash) that has an equal or higher number of zeros at the front than the target hash (the code every miner needs to beat)
- Whoever produces the winning hash that beats the target hash wins the right to fill a new block with transaction data and earn free crypto and transaction fees in return.
- Miners with more machines or those with machines with a higher hashrate (producing more hashes per second) have a greater chance of beating the target hash and winning the right to fill the next block with transaction data and adding it to the chain – and getting the reward.
- A corrupt group equaling a minimum of 51% – could intentionally confirm a malicious block containing altered data (in their favor you’d assume) – therefore destroying the integrity of the chain.
- A successful attack can block new transactions from being confirmed, as well as change the ordering of new transactions. It also allows the malicious agents to essentially rewrite parts of the blockchain and reverse their own transactions, leading to an issue known as double spending.
- A 51% attack, however, is theoretically limited in the amount of disruption it can cause. While the attacker could trigger double-spending, they cannot reverse others’ transactions on the network or prevent users from broadcasting their transactions to the network.
- Additionally, a 51% attack is incapable of creating new assets, stealing assets from unrelated parties or altering the functionality of block rewards.
- As a blockchain network grows and acquires news mining nodes it makes the chances of a 51% attack taking place less likely. That is because the cost of performing a 51% attack rises in tandem with the network hashrate (the amount of computational power needed.)
- The bigger the network and the more nodes there are participating in it, the more hash power is needed to control over 50% of it.
Proof Of Stake, The First Solution
- Proof of Stake was designed to remove the 51% pitfall, and replace it with mining rewards given to those with the most value staked in the given chain.
- So the cost of malicious alteration outweighs the value of their investment.
- When a blockchain is deemed corrupt all value is lost, so having a large stake in the integrity becomes much more important.
- Proof of Authority designed to use much less resources. PoA 2.0 blends the Byzantine Fault Tolerance (BFT) and Nakamoto Consensus types.
- BFT allows distributed networks to agree and execute based on majority say.
- The Nakamoto Consensus verifies the authenticity of a blockchain network – eliminating malicious actors in the BFT by randomizing validator selection.