Centralized databases that are run and maintained by people don’t need consensus mechanisms. However, permissionless and public distributed ledgers like a blockchain need consensus mechanisms to maintain state and legitimacy on the network. A consensus is programmatically hardcoded, reliable, fair, transparent, and doesn’t require external inputs.
In a government set up, a bill is approved if the majority of the legislators vote to pass it. Consensus algorithms, in a similar fashion, help nodes on a blockchain network agree upon an outcome while maintaining security. It protects the network from double spending (a condition that allows miners/validators to spend crypto they don’t own) and malicious attacks. There are two major widely used consensus mechanisms today: Proof of Work and Proof of Stake.
What is Proof of Work Consensus?
Proof of Work (POW) is the consensus mechanism used in Bitcoin and forks of Bitcoin like Bitcoin Cash. In Proof of Work, a miner uses energy to compete with other miners in the network to find the hash of a block of transactions. A hash is a unique string of alphanumeric characters that acts as the identifier of a block. A side note here – an appropriate hash or more specifically nonce depends on the processing power of your computer (mining device/node) rather than any particular skill.
Once a node finds the perfect nonce, he/she will get the opportunity to verify and update transactions on a block. The block is then broadcasted to other nodes on the network. If the majority of network nodes (greater than 51%) agree that the block is valid, the block is appended to the blockchain. The miner node is rewarded for its work in return.
Problems with Proof of Work
The Bitcoin blockchain is said to consume energy equivalent to a handful of smaller countries combined. By September 2021, Bitcoin’s yearly energy consumption topped 91 TWh, which was more than what Finland consumed annually. According to this Bitcoin energy consumption index, BTC now burns over 200 TWh.
Proof of Work algorithms, further, require sophisticated hardware. In the early days of Bitcoin, miners used PCs. This changed with the introduction of GPU, FPGA, and ASIC mining rigs that were faster and better at mining. Today, expensive ASIC miners dominate the Bitcoin network, thus setting a huge barrier for new entrants which in turn affects decentralization.
What is Proof of Stake Consensus?
First introduced by Peercoin, Proof of Stake is a consensus mechanism used by many blockchains today. POS requires node operators to stake a certain amount of the network’s coins in exchange for validation rights within the network.
Node operators, also known as validators, do not compete with each other. Instead, the consensus involves randomly selecting an operator node to find a new block based on their staked amount. Proof of stake is considered to be fast and energy efficient, as it removes the need for sophisticated equipment.
The POS consensus introduces a crypto-economic model in which validators are disincentivized from acting dishonestly. Should a validator node try double-spending, a portion or the entirety of their stake is slashed. Slashing results in a loss of staked funds for the validator. Slashed crypto is either sent to a governance wallet or burned.
Problems with Proof of Stake
A validator with a large enough stake on the network can get nominated more often than others. Thus, they can skew the network in their favor by staking a large amount of the network’s coins. This gives rise to the possibility of a 51% attack and earns itself the problem of “rich gets richer” tag. Over the years, different variations of PoS algorithm have been finding relevance to make staking more democratic. Let’s see a few of them.
Proof of Stake Consensus Variants
Delegated Proof of Stake (DPOS): The Cardano and EOS networks use DPOS or the delegated Proof of Stake consensus. In DPOS, token holders delegate the authority to validate new blocks by voting for a certain number (usually 20 to 100) of delegates.
Users can choose to delegate their votes to a different validator at any time. This ensures that validators are honest or else they risk being abandoned by the delegators. The delegators receive a share of the validator rewards in proportion to their staked amount and are not slashed if the validator misbehaves.
Nominated Proof of Stake (NPOS): Polkadot uses NPOS. NPOS is similar to DPOS with a few key differences. Block rewards are equally shared amongst the nominators. This ensures that rewards are not disproportionately distributed. Nominators stand to lose their stake for the actions of their validator. So they must be careful in choosing who they nominate.
Pure Proof of Stake (PPOS): Algorand uses PPOS. Pure Proof of Stake sets extremely low collateral to participate, maximizing decentralization. However, there’s no slashing mechanism. It relies on the majority (at least two-thirds) of the network to act honestly. Any network participant can be randomly and secretly selected to propose a block. The weight of their proposal is directly proportional to their stake. Undermining the network would result in the devaluation of their stake, so participants refrain from acting dishonestly.
Masternode Proof of Stake: Dash first introduced masternode based POS. Masternodes are nodes that offer certain governance rights to validators in addition to validating rights.
Liquid Proof of Stake (LPOS): Tezos uses LPOS. Token holders can nominate validators without transferring their tokens or choose to stake their own funds to nominate themselves. As many as 80000 validators can be delegated to produce a block at a time.
Consensus mechanism in blockchain technology reinforces the security of commercial transactions on top of cryptography and encryptions. Also by allowing consensus to be reached among unrelated node operators (like individual users) on a transaction, you are bringing decentralization to the ecosystem. Something we needed especially after 2008 financial crisis and other manufactured crisis over time. The conversation is slowly moving from ‘what is the solution’ to ‘how best to execute the solution’. We are now debating how various consensus algorithms could be leveraged to prevent even a 0.1% chance of a malicious attack or takeover.
Further, public distributed ledgers are transparent while at the same time protecting the privacy of valid users which was stripped off from us long back in the Web 2.0 world. Let’s say cheers to each other not because we have the solution. But because such solutions require iterative work to improve upon the architectures of Web 2.0 and truly restore the power back to people.
EVM Wallet Benefits | Cryptocurrency Liquidity Provider | Blockchain Layers Explained | Main Features of Web 3.0 | EVM Blockchains Add EVM Network | Difference Non Custodial Wallets and Custodial Wallets | Decentralized Identifiers | Cryptocurrency Career Opportunities | What is Consortium Blockchain | Major Components of Blockchain | What is a Flash Loan Attack | Popular Metaverse Platforms | List of Blockchain Platforms | Cross Chain Ecosystem Interoperability | Best Cross Chain Bridge | What is a Mainnet | List of Wrapped Tokens | Types of Sharded Blockchain | How Do Crypto Faucets Work | What is Layer 1 Blockchain
Opinions expressed in this publication are those of the author(s). They do not necessarily purport to reflect the opinions or views of Shardeum foundation.
About the Author : Shriraam Sekar is a crypto writer/marketer involved in the space since 2019. He covers Layer 1s, DeFi, NFTs, Metaverse, GameFi, SocialFi, and crypto regulations. Follow him on Twitter for collaboration related to crypto/Web 3.0