The blockchain is a decentralized database that allows users to exchange and store value in the form of cryptocurrencies. To manage and maintain such a decentralized system, members must agree on the system’s current state and who owns what at any one time.
A consensus mechanism is an established method by which the blockchain’s nodes reach this agreement in a reliable manner. This article will go over what the Consensus Mechanism is, How it works, and the various types of Consensus Mechanisms available.
What Is Consensus Mechanism?
A “consensus mechanism” is a procedure for achieving an agreement among a collection of network nodes. A consensus mechanism’s objective is to ensure that all nodes in a network agree on the state of the blockchain.
Consensus methods are essential for the successful operation of any blockchain protocol. They are in charge of filtering out invalid transactions, guaranteeing high levels of security for users, and ensuring that each action is reviewed and approved in milliseconds.
There are other sorts of consensus procedures, however as previously stated, the most prevalent are proof of work and proof of stake.
How Consensus Mechanism Works
A central administrator has the authority to maintain and update any centralized system, such as a database containing critical information regarding driving licenses in a country. The responsibility of making any adjustments, such as adding/deleting/updating names of those who qualified for various permits, is undertaken by a central authority, which remains solely responsible for keeping legitimate records.
Public blockchains operate on a worldwide scale as decentralized, self-regulating networks with no central authority. They entail contributions from hundreds of thousands of participants who work on the verification and authentication of blockchain transactions as well as block mining activities.
In the face of the blockchain’s dynamically changing status, these publicly shared ledgers require an efficient, fair, real-time, functional, reliable, and secure mechanism to ensure that all transactions occurring on the network are genuine and that all participants agree on a consensus on the ledger’s status.
This critical role is carried out by the consensus mechanism, which is a system of rules that determines the legality of contributions made by the blockchain’s various participants (i.e., nodes or transactors).
Types Of Consensus Mechanism
There are many different types of consensus mechanisms, but the most common are proof of work and proof of stake.
Proof of Stake (PoS)
This common way of reaching an agreement focuses on a process known as staking. In a proof of stake (PoS) system, miners must promise a ‘stake’ of digital money in order to be picked at random as a validator. The procedure is similar to a lottery in that the more coins you stake, the higher your odds.
In contrast to the PoW system, where miners are rewarded with block rewards (newly produced currencies), individuals that contribute to the PoS system merely get a transaction fee.
PoS is seen as a more environmentally friendly and sustainable option to PoW, as well as one that is more safe against a 51% attack. However, because the system favors entities with more tokens, PoS has been criticized for its propensity to lead to centralization. Prominent PoS platforms include Cardano (ADA), Solana (SOL), and Tezos (XTC).
Proof of Work (PoW)
Proof of work (PoW), which is used by Bitcoin, Ethereum, and many other public blockchains, was the very first consensus method invented. It is often regarded as the most reliable and secure of all consensus algorithms, while questions about scalability abound. While the concept “proof of work” was coined in the early 1990s, Bitcoin founder Satoshi Nakamoto was the first to apply it in the context of digital currencies.
Miners fight against one another in PoW by solving exceedingly complicated computational puzzles with high-powered computers. The first person to generate the 64-digit hexadecimal number (‘hash’) wins the ability to create the next block and confirm the transactions. A predetermined quantity of cryptocurrency known as a ‘block reward’ is also awarded to the victorious miner.
The running expenses of PoW are notoriously high due to the massive amount of computational resources and energy required to generate fresh blocks. This creates a barrier to entry for new miners, raising concerns about centralization and scalability.
And it’s not just the expenditures that are too expensive. The most prevalent objection leveled towards PoW is the environmental impact of power use. As a result, many people are looking for more sustainable, energy-efficient consensus methods, such as proof of stake (PoS).
Delegated Proof of Stake (DPoS)
Delegated proof of stake (DPoS), a variation of the PoS consensus process, achieves consensus through a reputation-based voting system. The network’s users ‘vote’ for ‘witnesses’ (also known as ‘block makers’) to secure the network on their behalf. Only the highest tier of witnesses (those with the most votes) can validate blockchain transactions.
Users vote by staking their tokens in a pool. Votes are then weighted based on the value of each voter’s stake, with more skin in the game equaling more voting power. Elected witnesses who successfully verify transactions in a block are rewarded, and this payment is frequently shared with people who voted for them.
Top-tier witnesses are always at risk of being replaced by those judged more trustworthy and so receiving more votes. They can even be voted out if they fail to carry out their duties or attempt to approve fraudulent transactions. This serves to motivate witnesses to be truthful at all times, maintaining the blockchain’s integrity.
Though less common than PoS, many consider DPoS to be more efficient, democratic, and financially inclusive than PoS. Lisk (LSK), EOS.IO (EOS), Steem (STEEM), BitShares (BTS), and Ark utilize it (ARK).
Proof of Authority (PoA)
Proof of authority (PoA), not to be confused with proof of activity (also ‘PoA’), operates by selecting validators based on reputation. It is a modified version of PoS that was proposed in 2017 by Ethereum co-founder and former CTO Gavin Wood.
Validators do not stake coins in PoA. Instead, they must risk their reputations in order to validate blockages. This is in stark contrast to the majority of blockchain protocols, which often do not require you to expose your identity in order to participate.
Proof of authority (PoA), not to be confused with proof of activity (also ‘PoA), operates by selecting validators based on reputation. In 2017, Ethereum co-founder and former CTO Gavin Wood presented a modified version of PoS.
Validators in PoA do not stake coins. Instead, they must stake their reputations in order to validate blocks. This is in contrast to the majority of blockchain protocols, which often do not require you to divulge your identity in order to participate.
Proof of Elapsed Time (PoET)
Proof of elapsed time (PoET), which is typically employed on permissioned blockchain networks (those that require participants to identify themselves), uses trusted computing to enforce random waiting times for block construction. It was created in early 2016 by Intel and is based on a specific set of CPU instructions known as Intel software guard extensions (SGX).
PoET is a time-lottery-based consensus mechanism that operates by allocating distinct wait times to each node in the network at random. During the waiting period, each of these nodes enters into sleep mode for the duration provided. The mining rights are awarded to the first person to wake up (that is, the one who has waited the least amount of time). This randomization ensures that each player has an equal chance of winning, providing network fairness.
The PoET consensus process is highly efficient, requires fewer resources, and is scalable. It has been incorporated into Hyperledger Sawtooth.
Proof of History (PoH)
Proof of History (PoH), as the name implies, gives evidence of historical events. Solana created PoH, which allows ‘timestamps’ to be embedded into the blockchain itself, confirming the passage of time between transactions without relying on other nodes.
This method of timestamping is made possible by an SHA-256, sequential-hashing verified delay function (VDF). It works by taking the outcome of a transaction and using it as the input for the next hash, allowing everyone to see which event occurred in a specific sequence.
PoH significantly minimizes the processing weight of the blockchain, making it faster and more energy-efficient than many of his peers because the VFDs can only be solved by a single CPU score. PoH has yet to be evaluated on a broad scale because it is only used by Solana.
Proof of Burn (PoB)
Proof of burn is another more sustainable alternative to Bitcoin’s PoW algorithm (PoB). Miners earn the ability to mine a block in PoB by ‘burning’ (destroying) a predetermined amount of tokens in a verifiable manner, notably by sending them to an ‘eater address’ where they cannot be reclaimed or spent. The more coins are destroyed, the more likely it is that you will be chosen at random.
Unlike PoS, where miners can recover or sell their locked coins if they quit the network, burned coins are irreversibly destroyed. This strategy of asking miners to forego short-term income in order to obtain the lifetime privilege of creating new blocks encourages miners to commit long-term.
The act of burning coins also leads to coin scarcity, limiting inflation and driving up demand. Cryptocurrencies that use the proof of burn protocol include Slimcoin (SLM), Counterparty (XCP), and Factom (FCT).
Proof of Activity (PoA)
Proof of activity (PoA) is a consensus process that combines the PoW and PoS consensus mechanisms. It is utilized by the blockchain projects Decred (DCR) and Espers (ESP).
In PoA systems, mining begins similarly to PoW, with miners vying to solve an intricate mathematical problem utilizing massive processing power. However, once the block has been mined, the system changes to PoS mode, with the successfully created block header being broadcast to the PoA network.
A group of validators is then chosen at random to sign off on the hash, therefore validating the new block. As with PoS, the more crypto the validator owns, the more likely they are to be chosen. When every validator has signed the block, it is put into the blockchain network and available for recording transactions. The block rewards are then shared among the miner and validators.
Though the PoA system was supposed to combine the greatest characteristics of PoW and PoS while avoiding their flaws, it has received criticism for its energy-intensive mining phase and natural preference for validators with a larger quantity of coins.
Proof of Capacity / Proof of Space (PoC / PoSpace)
Unlike the majority of its predecessors, which granted mining rights based on processing power or coins staked, proof of capacity (PoC) – sometimes known as proof of space (PoSpace) – bases its mining method on the amount of hard drive space accessible to a miner.
In PoC, miners construct a list of all possible hashes ahead of time through a process known as ‘plotting.’ After that, the plots are saved on a hard disk. The greater a miner’s storage capacity, the more feasible solutions. The more solutions there are, the more likely it is that you will have the correct combination of hashes and hence win the payout.
PoC allows the typical individual to engage in the network because it does not require expensive or specialized equipment. As a result, it is a less energy-intensive and more decentralized alternative to some of the more common consensus processes discussed in this tutorial.
However, few developers have decided to use the system as of yet, and there are concerns regarding its vulnerability to virus assaults. Signum (SIGNA), formerly Burstcoin (BURST), Storj (STORJ), and Chia are now using the technique (XCH).
Proof of Importance (PoI)
Proof of Importance (PoI), first established by NEM (XEM), selects miners based on specific criteria in a process known as ‘harvesting.’ The quantity and size of transactions in the last 30 days, the amount of vested currency, and network activity are all common considerations. Nodes are assigned a significance score based on these variables. The higher the score, the more likely it is that you will be chosen to harvest a block and get the associated transaction fee.
Though comparable to PoS, PoI’s usage of extra measures eliminates the former’s inclination to naturally favor the wealthy by taking into consideration members’ total network support. As a result, just staking high in POI does not ensure a chance to win the block.
The consensus mechanism is just a way of establishing agreement on the validity of data or transactions in a specific blockchain network. Without attaining consensus, it is nearly difficult for blockchain to function as intended. According to an IBM survey, 90% of operational procedures include some type of unstructured interaction between employees and suppliers, customers, partners, or others with whom they often contact.