avatarPrerana Kulkarni

Free AI web copilot to create summaries, insights and extended knowledge, download it at here

2333

Abstract

mber of traitors.</li></ol><figure id="4b5c"><img src="https://cdn-images-1.readmedium.com/v2/resize:fit:800/1*32sNwfya0-mKwIEMe0qsBQ.jpeg"><figcaption></figcaption></figure><p id="a2df"><b>How Blockchain is BFT (Byzantine Fault Tolerant)?</b></p><p id="f663">In a traditional banking system, only a centralized authority can record the transactions and update the balance, thus preventing double-spending. Double-spending means spending the same amount twice; it can be accidental or malicious.</p><p id="91fd">Bitcoin, the first application of Blockchain technology, is a peer-to-peer digital cash system having a network of trustless nodes (peers) with no central authority. In a peer-to-peer system without centralized authority, preventing Double-spending attacks and other malicious attempts to tamper with the transactions or balances can be challenging.</p><p id="df64">Let’s see the analogy; consider all the active nodes as generals (probably including some malicious nodes), and the act of creating & adding a valid block containing all valid transactions is the consensus they have to attain. Malicious nodes acting as traitors will try to double spend or add an unverified block to the chain and benefit from the rewards.</p><p id="7cfb">Bitcoin prevents these types of attacks with asymmetric cryptography and a consensus algorithm, <b>Proof-Of-Work</b> (POW).</p><ol><li>Asymmetric Cryptography: Every transaction is cryptographically signed using public-private key pair and is verified by the nodes. Hashing algorithms, the Merkel tree, and how each block would have the previous block hash make the blocks tamperproof, so the traitors cannot break in.</li><li>Proof-Of-Work: The nodes must race to solve a complex mathematical puzzle with varying difficulties. Only the node that solves it first gets to add the new block to the blockchain and receives reward & transaction fees. All other nodes agree and update their local copies accordingly. POW ensures that if the traitors or malicious nodes attempt to alter any block or perform double spending, they would have to solve the complex mathematical puzzle and build every block that comes after that particular block in the blockchain, which will be very expensive and practically infeasible. To force any invalid block in the blockchain, one needs to own

Options

more than fifty percent of computing nodes, which is an unachievable task, given there are thousands of nodes in the network.</li></ol><p id="d34c"><b>Proof-Of-Stake, or </b>POS, is another consensus algorithm used widely. A validator is selected based on the proportion of tokens it’s staking. The more the stakes grow, the higher the chance of getting picked as a validator. A validator is a node that can add a new block to the blockchain; it needs to commit the tokens for a certain period to the network, known as staking. Validators act in good faith because they are staking their tokens too. In addition, they receive block rewards on a successful addition of the block. POS is gaining popularity over POW because it requires less computing power, so more environmentally friendly. Cardano, Cosmos, Polkadot, Solana, and now Ethereum 2.0 are among many popular cryptocurrencies that use the POS consensus mechanism.</p><p id="59d7">If you would like to know more about Ethereum’s transition from POW to POS, read <a href="https://readmedium.com/the-merge-setting-stage-for-further-scalability-1ba08776c4d8">The Merge</a>.</p><p id="7e61">References:</p><p id="1917"><a href="https://en.wikipedia.org/wiki/Byzantine_fault">https://en.wikipedia.org/wiki/Byzantine_fault</a></p><p id="20c8"><a href="https://lamport.azurewebsites.net/pubs/byz.pdf">https://lamport.azurewebsites.net/pubs/byz.pdf</a></p><blockquote id="bdc6"><p>If you found my article informative, consider joining Medium to read many more such informative and engaging stories written by talented writers for just $5 a month. To become a member, please click <a href="https://medium.com/@preranakulkarni/membership">here</a>.</p></blockquote><p id="072a">Here are a few more pieces by Prerana Kulkarni on Blockchain Technology:</p><p id="3f6a"><a href="https://readmedium.com/what-is-blockchain-technology-3d064e958ee7">What Is Blockchain Technology?</a></p><p id="d4d6"><a href="https://readmedium.com/the-merge-setting-stage-for-further-scalability-1ba08776c4d8">The Merge: Setting Stage for Further Scalability.</a></p><p id="c828"><a href="https://readmedium.com/blockchain-fad-or-future-3aa41fb8b216?source=your_stories_page-------------------------------------">Unlocking the Potential of Blockchain: A Path to Mainstream Adoption</a></p></article></body>

Know Why Blockchain Technology is Byzantine Fault Tolerant: Consensus Algorithm!

What is Byzantine Fault? How is Blockchain BF Tolerant? If you don’t know, now you know about this essential design feature of any decentralized system. Explained in a simple way that a middle schooler would understand.

Photo by Raimond Klavins on Unsplash

The term ‘Byzantine Fault’ or ‘Byzantine Generals’ problem’ is taken from the allegory ‘Byzantine Generals Problem’. The story refers to the Byzantine Empire, a long last chapter in History.

What is Byzantine Generals’ Problem?

Imagine a fortress surrounded by Byzantine generals. They are geographically separated and can communicate only through messages. They can either pull back or charge. All the generals must agree on either attacking or pulling back. Any tepid attack by a few generals would worsen the situation than either a coordinated attack or retreat. The complexity increases as traitors create chaos to stop the generals from reaching an agreement.

A Byzantine fault or a Byzantine General’s Problem is a condition typically seen in a distributed computing system, where one or more components fail or exhibit inconsistent behavior by sending conflicting information to the different parts of the system. The artifact ‘Byzantine generals’ problem’ abstractly describes coping mechanisms for these types of failure.

There are two solutions to resolve this problem:

  1. For every t number of traitors, there should be more than 3t+1 generals in the system.
  2. The messages communicated should be secured. With unforgeable and signed messages, any number of generals could cope with an arbitrary number of traitors.

How Blockchain is BFT (Byzantine Fault Tolerant)?

In a traditional banking system, only a centralized authority can record the transactions and update the balance, thus preventing double-spending. Double-spending means spending the same amount twice; it can be accidental or malicious.

Bitcoin, the first application of Blockchain technology, is a peer-to-peer digital cash system having a network of trustless nodes (peers) with no central authority. In a peer-to-peer system without centralized authority, preventing Double-spending attacks and other malicious attempts to tamper with the transactions or balances can be challenging.

Let’s see the analogy; consider all the active nodes as generals (probably including some malicious nodes), and the act of creating & adding a valid block containing all valid transactions is the consensus they have to attain. Malicious nodes acting as traitors will try to double spend or add an unverified block to the chain and benefit from the rewards.

Bitcoin prevents these types of attacks with asymmetric cryptography and a consensus algorithm, Proof-Of-Work (POW).

  1. Asymmetric Cryptography: Every transaction is cryptographically signed using public-private key pair and is verified by the nodes. Hashing algorithms, the Merkel tree, and how each block would have the previous block hash make the blocks tamperproof, so the traitors cannot break in.
  2. Proof-Of-Work: The nodes must race to solve a complex mathematical puzzle with varying difficulties. Only the node that solves it first gets to add the new block to the blockchain and receives reward & transaction fees. All other nodes agree and update their local copies accordingly. POW ensures that if the traitors or malicious nodes attempt to alter any block or perform double spending, they would have to solve the complex mathematical puzzle and build every block that comes after that particular block in the blockchain, which will be very expensive and practically infeasible. To force any invalid block in the blockchain, one needs to own more than fifty percent of computing nodes, which is an unachievable task, given there are thousands of nodes in the network.

Proof-Of-Stake, or POS, is another consensus algorithm used widely. A validator is selected based on the proportion of tokens it’s staking. The more the stakes grow, the higher the chance of getting picked as a validator. A validator is a node that can add a new block to the blockchain; it needs to commit the tokens for a certain period to the network, known as staking. Validators act in good faith because they are staking their tokens too. In addition, they receive block rewards on a successful addition of the block. POS is gaining popularity over POW because it requires less computing power, so more environmentally friendly. Cardano, Cosmos, Polkadot, Solana, and now Ethereum 2.0 are among many popular cryptocurrencies that use the POS consensus mechanism.

If you would like to know more about Ethereum’s transition from POW to POS, read The Merge.

References:

https://en.wikipedia.org/wiki/Byzantine_fault

https://lamport.azurewebsites.net/pubs/byz.pdf

If you found my article informative, consider joining Medium to read many more such informative and engaging stories written by talented writers for just $5 a month. To become a member, please click here.

Here are a few more pieces by Prerana Kulkarni on Blockchain Technology:

What Is Blockchain Technology?

The Merge: Setting Stage for Further Scalability.

Unlocking the Potential of Blockchain: A Path to Mainstream Adoption

Blockchain
Byzantine Fault Tolerance
Blockchain Technology
Education Technology
Blockchain Architecture
Recommended from ReadMedium