What is 51% Attack?

51% attack, also known as a double-spend attack is a nightmare for all crypto coins. Luckily, such an attack hasn’t materialized yet and is still a hypothetical scenario in the case of Bitcoin. It refers to a situation when a group of miners controls 50% or more of the mining hash rate in a particular blockchain network. A 51% attack is a direct attack on the blockchain network. It is a scenario that most commonly includes Bitcoin as the target. 

Are you wondering why this is a bad scenario for the blockchain or Bitcoin blockchain? The first of many problems is that the group of miners with 50%+ of mining hash rate power will be able to stop payment from going to users. In fact, such control over mining hash power would enable the miners to reverse transactions that are already complete. Hence, the miners can double-spend bitcoins. 

There are a few things that the miners with majority control over the blockchain mining power won’t be able to do. For starters, they won’t be able to create new coins on their own. Nor would they be able to make changes in the old blocks. The malicious actor with 51% control over the mining hash rate won’t be able to destroy any of the digital currencies based on blockchain. But such an attack will prove to be highly damaging for a bitcoin network and the blockchain. 

How Does 51% Attack Work?

Bitcoin Transactions

To understand the 51% attack, we will have to start with how Bitcoin transactions work. As soon as the BTC owner signs a transaction, it enters the mining pool of transactions which are unconfirmed. From this pool, miners select some of the unconfirmed transactions to create a block. 

The miners have to work through some of the very tough mathematical problems to add their blocks to the blockchain. They leverage computation power, also known as hashing power to solve these mathematical problems. Hence, a miner with high hashing power or computational power will find the solution to the mathematical problems faster than other miners. 

The information about the solution and the block will be broadcasted to other miners after a miner finds a solution for a mathematical equation. Now, other miners will verify all the transactions that are within the block. They will verify all these transactions to check if they are valid as per the blockchain’s current transaction record. 

How Would a Malicious Actor Impact Bitcoin Transactions?

Miners with 51% or more share of mining hash power would be able to reverse the current Bitcoin transactions. We know that the mathematical solution along with the block is broadcasted to all miners as soon as the solution is found. This is the part where a malicious miner or a group of miners decide to not broadcast the solution. It leads to the creation of two blockchain versions. 

Now, the first version is followed by the miners with no malicious intent. The second one is followed by miners with malicious intent. The malicious miners do not allow the mathematical solutions to be broadcasted to the rest of the mining network. Hence, this chain gets left behind and doesn’t get picked up by other miners. 

Now, the malicious miners can use all their Bitcoins in the honest version of the Bitcoin network. That is where all the miners with no malicious intent are working on solving bitcoin transactions. 

Suppose, if the malicious miners spend their bitcoins to purchase a piece of real estate. In this case, the blockchain with all honest miners will show that all the bitcoins are spent. But, the malicious miners do include the bitcoin transactions on the offshoot blockchain version. In this newly created blockchain version, the malicious miner still owns his bitcoins. 

The malicious miners are still continuing to pick up blocks of unverified transactions. They verify all of these transactions by themselves on their offshoot blockchain network. And that is when the real trouble begins. 

Blockchain’s core governance model is kind of a democracy. It adheres to the “Follow the Majority” model. The chains that are longest win in the blockchain. Hence, a race begins where the miners with most of the hash power will add the blocks of unconfirmed transactions to their chain faster. 

The Race to Reverse the Transactions 

The malicious miners are competing against honest miners. They are trying to get the blocks to add to the offshoot blockchain. Their aim is to do it faster than all other miners who are trying to add the blocks to the true version of blockchain. 

As the malicious miners create a longer chain, they broadcast it to the other miners. Now, the rest of the network realizes that the malicious blockchain is longer than theirs. Hence, the blockchain protocol makes them shift to the malicious chain. Now, the offshoot version of blockchain becomes the true blockchain. Hence, all transactions not part of this particular chain are immediately reversed. 

The malicious miners have already spent their bitcoins to purchase a piece of real estate. Yet, these transactions are not part of the offshoot blockchain that has become the true blockchain now. Hence, the malicious miners are again under the control of the bitcoins that they supposedly spent. They can spend them again if they wish to. This is what is commonly known as the 51% attack or double-spend attack. 

Is any Cryptocurrency More Susceptible to 51% Attack than the Others?

If one examines the mining protocol known as the Proof of Work, they will find that the crypto coins with comparatively more hashing power have more security against a double-spend attack. 

Smaller altcoins operating on the mining algorithm are more likely to face such an attack. Hence, smaller altcoins such as Bitcoin Gold are more susceptible to 51% attacks. On the other hand, the bitcoin blockchain has not seen any such attacks so far. 

Fears Around Mining Hardware Manufacturers 

The concerns about manufacturers of mining hardware such as ASICS harnessing too much power are growing. Many of the crypto enthusiasts believe that such concerns are valid. They think that mining hardware manufacturers are empowering the people with financial clout with more mining rigs.

A situation described above may result in a power imbalance as a small group of people with more mining rigs will hold more computing power than the rest. Such a scenario gives rise to the 51% attack. Monero, too, believes in these concerns. Hence, they blocked ASIC mining on the Monero network. Monero made it happen by updating its protocol. 

What are the Chances of 51% Attack on Bitcoin Happening in Reality?

The chances of a 51% attack on the bitcoin network are close to zero. It is because a Miner or group of miners will need an astounding amount of computing power to make this real. They will have to outcompete millions of bitcoin miners from around the world. A miner will require billions of dollars worth of equipment to wield such a huge amount of hash power. 

What if a miner plans to use the most powerful computers in existence today? Good luck to that as even such powerful computers won’t be able to outcompete millions of computers that are currently working to mine bitcoins. Hence, carrying out a 51% attack on the bitcoin network is extremely difficult. We haven’t yet accounted for the electricity costs here.

The additional burden of electricity costs will make such a plan unrealistic for the best of the best miners. But it does not mean that there’s no way for malicious actors to initiate a double-spend attack. 

A malicious miner could use a bug as a back door entry to the blockchain network. It would enable them to produce new blocks at a rate which is far more than the normal. Thus, they would be able to carry out a double-spend attack.