Consensus Algorithms.pptx

Rajapriya82 2,203 views 18 slides Feb 27, 2023
Slide 1
Slide 1 of 18
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18

About This Presentation

Consensus Approach and Types of Consensus Algorithms


Slide Content

Consensus Approach & Consensus Algorithm in Blockchain By S.Rajapriya,MS (IT) Assistant Professor of IT

CONSENSUS APPROACH We know that Blockchain is a distributed decentralized network that provides immutability, privacy, security, and transparency. There is no central authority present to validate and verify the transactions, yet every transaction in the Blockchain is considered to be completely   secured  and  verified . This is possible only because of the presence of the  consensus protocol  which is a core part of any Blockchain network.  A consensus mechanism is any method used to achieve agreement, trust, and security across a decentralized computer network. In the context of blockchains and cryptocurrencies , proof-of-work ( PoW ) and proof-of-stake ( PoS ) are two of the most prevalent consensus mechanisms.

Consensus mechanisms play an essential part of securing information by encrypting it and using automated group verification. The consensus protocol makes sure that every new block that is added to the Blockchain is the one and only version of the truth that is agreed upon by all the nodes in the Blockchain . The Blockchain consensus protocol consists of some specific objectives such as coming to an agreement, collaboration, cooperation, equal rights to every node, and mandatory participation of each node in the consensus process. Thus, a consensus algorithm aims at finding a common agreement that is a win for the entire network. CONT…

CONSENSUS ALGORITHM A consensus algorithm is a process in computer science used to achieve agreement on a single data value among distributed processes or systems. These algorithms are designed to achieve reliability in a network involving multiple users or nodes. Solving this issue -- known as the consensus problem -- is important in distributed computing and multi-agent systems such as those seen in cryptocurrency  blockchain networks.

How consensus algorithms work Consensus algorithms are vital in large-scale, fault-tolerant systems because they enable a set of distributed/replicated machines to work as a coherent group and agree on system state . Consensus algorithms assume some processes and systems will be unavailable and that only a portion of the nodes will respond. They also assume some communications will be lost during transmission. However, a response is required from the available nodes. For example, an algorithm may require that at least 51% of nodes respond to achieve consensus or agreement on a data value or network state.

Cont… This ensures consensus is achieved with minimal resources, even if the other resources are unavailable or even faulty. Scalability, privacy, security and fault tolerance must be considered for consensus algorithm. Resistance to attacks, node ID management, correctness proof and assumptions about network to be considered while deciding the algorithm to be used.

Types of consensus algorithms Let's explore the many types of consensus algorithms

1. Proof of Work The PoW algorithm is one of the oldest types of consensus algorithms. First introduced in 1993 -- and reintroduced in 2008 by Bitcoin founder Satoshi Nakamoto -- the central idea of PoW is to have nodes solve complex mathematical puzzles and make as many guesses as possible in the fastest possible time. This consensus algorithm is used to select a miner for the next block generation. Bitcoin uses this PoW consensus algorithm. The central idea behind this algorithm is to solve a complex mathematical puzzle and easily give out a solution. This mathematical puzzle requires a lot of computational power and thus, the node who solves the puzzle as soon as possible gets to mine the next block.

However, the process is not that easy. A puzzle can be solved only via trial and error method . Additionally, the level of complexity of the puzzle increases with the speed at which blocks are mined. So , it becomes mandatory for one to create a new block within a certain time frame to cope up with the difficulty level. The Proof of Work mechanism is used by multiple cryptocurrencies like Bitcoin , Litecoin , ZCash , Primecoin , Monero , and Vertcoin to name a few.  In bitcoin consensus algorithm each block is intended to generate a hash value, and the nonce is the parameter that is used to generate that hash value. In terms of its implementations, the Proof of Work ( PoW ) has not only influenced the financial industry, but also healthcare, governance, management and more .

2. Proof of Stake This is the most common alternative to PoW . Ethereum has shifted from PoW to PoS consensus. In this type of consensus algorithm, instead of investing in expensive hardware to solve a complex puzzle, validators invest in the coins of the system by locking up some of their coins as stakes. After that, all the validators will start validating the blocks. Validators will validate blocks by placing a bet on them if they discover a block that they think can be added to the chain. Based on the actual blocks added in the Blockchain , all the validators get a reward proportionate to their bets, and their stake increase accordingly. In the end, a validator is chosen to generate a new block based on its economic stake in the network. Thus, PoS encourages validators through an incentive mechanism to reach to an agreement .

The two popular variations of Proof of Stake ( PoS ) are Delegated Proof of Stake( DPoS ) Leased Proof of Stake( LPoS ) Delegated POS: This is another type of Proof of Stake consensus algorithm. This type of consensus mechanism depends on the basis of the delegation of votes. The users delegate their votes to other users. Whichever user then mines the block will distribute the rewards to the users who delegated to that particular vote. For example: if user A spends 10 coins for a delegate and user B invests 5 coins, A’s vote gets more weightage than that of B. DPoS is one of the fastest blockchain consensus models and highly preferred as a digital democracy. Some of the real-life  use cases of this blockchain consensus mechanism are Steem , EOS, and BitShares .

Leased Proof of Stake ( LPoS ) LPoS is an enhanced version of PoS consensus mechanism that operates on the Waves platform. In LPoS , users lease crypto tokens to the node that wants to act as a block producer for the network. A node with the maximum number of staked tokens is more likely to be selected for the next block generation as well as receive rewards. It also helps users with smaller tokens who might not have been eligible for participating as the blockchain creator in the traditional proof of Stake process in pooling their assets while enhancing their chances of receiving network transaction fees’ share. The leased proof of stake ( LPoS ) consensus algorithm is best for networks with high high -technical requirements for operating full nodes capable of verifying and validating transactions .

3.Proof of Activity In the case of PoA mechanism, miners race to solve a cryptographic puzzle at the earliest using special hardware and electric energy, just like in PoW . However, the blocks they come across hold only the information about the identity of the block winner and reward transaction . The validators (shareholders appointed to validate transactions) test and ensure the correctness of the block.  If the block was checked many times, the validators activate to a complete block. This confirms that open transactions are processes and are finally integrated into the found block containers.  Besides, the block reward is divided so that validators gain shares of it. The two real-world implementations of this mechanism are Espers and  Decred  coins .

4.Proof of Capacity ( PoC ) In the Proof of Capacity ( PoC ) mechanism, solutions for every complex mathematical puzzle are accumulated in digital storages like Hard disks. Users can use these hard disks to produce blocks, in a way that those who are fastest in evaluating the solutions get better chances for creating blocks.  The process it follows is called Plotting. The two cryptocurrencies that rely on PoC blockchain consensus protocol are Burstcoin and SpaceMint .

5. Proof of Elapsed Time ( PoET ) PoET was introduced by Intel with an intent to take over cryptographic puzzles involved in PoW mechanism by considering the fact that the CPU architecture and the quantity of mining hardware knows when and at what frequency does a miner win the block.  It is widely used in permissioned Blockchain networks. It is based on the idea of fairly distributing and expanding the odds for a bigger fraction of participants. And so, every participating node is asked to wait for a particular time to participate in the next mining process. The member with the shortest hold-up time is asked to offer a block. 

At the same time, every node also comes up with their own waiting time, after which they go into sleep mode.  So, as soon as a node gets active and a block is available, that node is considered as the ‘lucky winner’. This node can then spread the information throughout the network, while maintaining the property of decentralization and receiving the reward .

6.Proof of Burn ( PoB ) Considered an alternate solution to PoW and PoS in terms of energy consumption, Proof of Burn ( PoB ) consensus model works on the principle of letting miners ‘burn’ or ‘ruin’ the virtual cryptocurrency tokens, which further provides them with a privilege to write blocks in proportion to the coins. The more coins they burn, the more are the chances of picking the new block for every coin they get.  But, in order to burn coins, they are required to send it to the address where it couldn’t be spent for verifying the block.  This is widely employed in the case of distributed consensus. And the finest example of this consensus mechanism is the Slim coin.

THANKYOU