0% found this document useful (0 votes)
14 views7 pages

Consensus Algorithm

The document discusses various consensus algorithms, focusing on Proof-of-Work (PoW) and Proof-of-Stake (PoS). PoW, used by Bitcoin, is energy-intensive and has low transaction throughput, while PoS, which selects validators based on staked coins, is more energy-efficient but faces challenges like the 'nothing at stake' problem and centralization risks. Both algorithms have their limitations and ongoing developments aim to address these issues in blockchain technology.

Uploaded by

womomes759
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views7 pages

Consensus Algorithm

The document discusses various consensus algorithms, focusing on Proof-of-Work (PoW) and Proof-of-Stake (PoS). PoW, used by Bitcoin, is energy-intensive and has low transaction throughput, while PoS, which selects validators based on staked coins, is more energy-efficient but faces challenges like the 'nothing at stake' problem and centralization risks. Both algorithms have their limitations and ongoing developments aim to address these issues in blockchain technology.

Uploaded by

womomes759
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

consensus algorithm is a mechanism that manages which participants in the

network get to set the state of truth that everyone else follows and agrees on. In
reference to how secure the agreement is, the algorithm applications include: 
Determining whether a database can execute a decentralized transaction. 
Designating a supervisor for A decentralized task.  Coordinating and maintaining
consistency amongst duplicates of automata. Some of the popular consensus
algorithms are Proof-of-Work (PoW), Proof-of-Stake (PoS), Proof-of-Activity
(PoA), Proof of Vote (PoV), Proof of ElapsedTime (PoET), Proof-of-Importance
(PoI), Proof-of-Capacity (PoC), Proof-of-Burn (PoB). This paper will primarily
focus on PoW, PoS, PoA, and PoV.

PoW Proof of Work, in short PoW, was first developed in 1993 [1] to avoid denial-
of-service assaults and misuse of other services. [20] The goal of a connection
depletion attack is to overwhelm a server's resources and prevent it from
responding to valid queries by submitting a significant amount of connection (or
service) requests that are left unanswered. In the year 2009 [2,8], Bitcoin pioneered
a revolutionary use of proof-of-work as a consensus mechanism, broadcasting new
blocks to the blockchain and validating transactions. It then attracted attention and
is now a frequent consensus algorithm in several cryptocurrencies. Bitcoin is a
blockchain-based architecture that is supported by decentralized nodes working
together. The miners among all these nodes oversee bringing additional blocks to
the blockchain. Miners must attempt to guess a fictitious random number to
accomplish this. The above number must generate a result that meets the
requirements when concatenated with the block's data and runs through a hashing
algorithm. When a relationship has been established, some other nodes will
validate the effectiveness of the detection, and the mining node will receive a new
block incentive. As a result, finding a valid nonce [nonce is a random 32-bit
number that miners use as a base for their hash calculations] is a prerequisite for
adding a block to the main chain. [3,8] This nonce provides the solutions to a
particular block known as BLOCK-HASH. [9] It is named proof-of-work because
each authenticated block contains a block hash that symbolizes the miner's labor.
Proof-of-work helps defend the network against a variety of intrusions. [21] One
problem with proof-of-work is that it necessitates expensive computer machinery
that uses a lot of power, and while complex algorithm computations ensure
network security, they cannot be used for anything else. Even though proof-of-
work would not be the most effective approach, it is nevertheless one of the most
widely used techniques for achieving consensus in blockchains. Alternative
approaches and methodologies are being used to address the issues. However, time
will only tell which solution will replace the proof-of-work strategy.

How Does Proof of Work function?


Suppose there is a transaction that needs to be added to the blockchain. This
transaction will go into a pool of unconfirmed transactions called a mempool.
Then, miners will pick up this transaction from the mempool and start working on
it. They do this by using their computing power to solve complex mathematical
problems.
The mathematical problem that is being referred to here is a hash. Since there is no
way to reverse engineer a hash algorithmically, the only way to go about doing so
is through a trial and error method.

Hence, the greater the processing power of the mining computer, the greater the
likelihood of getting to the solution first.
The first miner who solves the problem adds the block of transactions to the
blockchain and thus earns their block reward. The other miners then verify that the
solution is correct and start working on the next block of new transactions.

PoS The Proof-of-stake method was first proposed in 2011 by an unknown user by
the username Quantummechanic on the bitcointalk site [30]. The fundamental idea
is that it serves no use to allow people to compete with one another in mining.
Therefore, Proof-of-Stake employs an election procedure in which one node is
selected at random to validate the following block. However, there is a subtle
change in terminology: Proof-of-Stake uses "validators" instead of miners, [1,36]
and new blocks are "minted" or "forged" rather than mined. The selection of
validators is not entirely random. A node must stake a particular amount of coins
into the network to become a validator. One may consider this to be a security
deposit. The stake size determines the likelihood that a validator will be selected to
forge the next block. Rich individuals can benefit from the strength of economies
of scale with PoW. The cost of their electricity and mining equipment does not
increase linearly; rather, the more they purchase, the better pricing they can obtain.
But returning to PoS, if a validator is selected to forge the following block, he will
determine whether all of the transactions included therein are, in fact, valid. The
costs connected with each transaction in this block go back to the validator as a
[Link] they nonetheless allow fraudulent transactions, validators will lose a
portion of their investment [2,36]. A validator can be relied on to perform their
duties effectively as long as the stakes are higher than what they stand to gain from
transaction fees. Otherwise, they will lose incentives instead of making it. It
functions as a financial motivator and endures so long as the stake exceeds the total
of all transaction fees. After a predetermined amount of time, if one node ceases to
be a validator, his stake as well as all transaction fees received will be removed.
Since Proof-of-Stake prevents everyone from mining for new blocks, it consumes
far less energy [1,14]. Moreover, it is more decentralized. "Mining pools" are a
prospect that exists within the proof-of-work protocol. The pool refers to the
individuals that are working together to raise their chances of mining a new block
and thus obtaining rewards. However, these pools now have control over a sizable
piece of the Bitcoin blockchain. They concentrate on the mining process, which is
risky. The network would have had a majority share and could have started
authorizing fake transactions if the three largest mining pools had united. PoS
encourages more users to set up a node because no expensive mining equipment is
required, which increases the network's decentralization and security. But even
PoS has several drawbacks and is far from being a flawless [Link]
who purchases the majority of the network's shares will be able to effectively rule
it and sanction fraudulent transactions. The 51% attacks, as it is known, were
initially cited as a flaw in the Proof-of-Work method. If a single miner or group of
miners can gather 51% of the hash power, they can effectively take over the
Blockchain. On the other hand, Proof-of-Stake makes this approach exceedingly
impractical because it depends on the value of a coin. If bitcoin were changed to
PoS, it would cost an astounding amount of money to own 51% of all coins.
Therefore, Proof-of-Stake reduces the likelihood of a 51% attack. The process
through which PoS mechanisms choose the subsequent validators must be heedful.
Since the stake size must be taken into account, it cannot be chosen at random.
However, the stake alone is insufficient because it will favor wealthy individuals,
who will be selected more frequently, receive more incentives and become
wealthier, increasing their chances of being selected as validators even further.
There are several solutions to the coin age selection problem. Another potential
issue is when the network selects the following validator but he fails to show up to
perform his duties. By selecting a large number of backup validators as a fallback,
this might be readily resolved. When compared to PoW, Proof-of-Stake entails
more hazards, and much research is required to comprehend these dangers and
mitigate [Link], Lisk, and Nxt are a few examples of coins that use Proof-
of-Stake, but more are expected 49 Volume 9 (2023), Issue 3 Blockchain: A
Comparative Study of Consensus Algorithms PoW, PoS, PoA, PoV to follow in
the future. For instance, the "Casper" Proof-of-Stake system is being implemented.
Casper is a consensus mechanism in which the PoW/PoS collaborate [3,36]. It is
actively being developed and is now available on the Ethereum test net.
Additionally, the Ouroboros Proof-of-Stake is being developed to preserve the fair
leader election process that guarantees the security of the protocol [37].

How Does Proof of Stake function?


Once you stake the minimum required amount of cryptocurrency on-chain, you are
eligible to validate transactions.
The validators are chosen randomly to validate the next block of transactions. The
more Proof of Stake cryptocurrency you stake (such as ETH), the greater your
chances of being chosen as a validator.
Once a validator has been chosen, they validate the block of transactions and add it
to the blockchain. They are then rewarded with cryptocurrency for their efforts.
Since a single validator produces blocks, how does the network ensure that the
validator does not engage in nefarious activity for personal benefit?
Validators participate in consensus by staking tokens on the crypto network
This is where the concept of “slashing” comes in. Slashing is when a validator's
stake is taken away as a punishment for engaging in malicious behavior.

For instance, if a validator tries to validate two different blocks at the same time,
they will be caught and their stake will be slashed. This serves as a disincentive for
validators to cheat PoS systems.
Limitations of Proof of Work
Proof of Work was invented by Cynthia Dwork and Moni Naor in 1993 as a way to
prevent DDoS (Distributed Denial of Service) attacks. It was only later that it was
adapted for use as a cryptocurrency consensus mechanism.

Since it's a legacy consensus model, it has its fair share of shortcomings that need
to be overcome in order to address the blockchain trilemma of decentralization,
scalability, and security.

Energy-intensive
Proof of Work is very energy-intensive. This is not just because miners need to run
powerful computers to validate transactions for the block rewards, but also because
all miners have to run for all transactions even though only one of them is
rewarded.

This renders a great amount of energy waste and also leaves a significant carbon
footprint.

For example, Bitcoin alone consumes about 110 Terra-Watt hours of energy per
year, which is more than the annual power consumption of countries like Finland,
Norway, and Bangladesh. Some estimates even put this figure at up to 150 Terra-
Watt hours per year, as much energy consumption as the entire country of
Argentina.

Low throughput
The Proof of Work system also suffers from low transaction throughput. This is
because the time it takes to mine a new block and add it to the blockchain is fixed.
For Bitcoin, this time is roughly fixed at 10 minutes. This means that the network
can only process a maximum of 7 transactions per second. In comparison, Visa
processes about 1,700 transactions per second (with some figures estimated at up
to 65,000 transactions per second).

Expensive
Another drawback of Proof of Work blockchains is that they require high
computational power to participate in the mining process. This creates a barrier to
entry for most people and also centralizes power among those who can afford
expensive computers capable of delivering such power.

The high cost of entry also leads to the centralization of power among miners,
which goes against the decentralized nature of blockchain technology.

Limitations of Proof of Stake


Scott Nadal and Sunny King are the two developers who invented Proof of Stake.
According to them, the Proof of Work consensus mechanism used by the Bitcoin
network and its forks are detrimental to the environment and present scalability
issues that would hinder the mass adoption of cryptocurrency as a payment system.

Proof of Stake was therefore developed to be more energy-efficient and overcome


the obvious challenges posed by Proof of Work.

But Proof of Stake also has limitations.

“Nothing at stake” problem


The “nothing at stake” problem is a challenge inherent in Proof of Stake where an
attacker can easily fork the blockchain and create two different versions of the
truth. This is because there is no incentive for validators to stay loyal to one chain
as they can verify transactions on both chains and get rewards from both.
The nothing at stake problem was first proposed by Ethereum co-founder Vitalik
Buterin in 2014 and is still a challenge that needs to be addressed by developers.

High stake requirement


Another limitation of Proof of Stake is that it requires validators to have a high
stake in the network. This is because validators would only be motivated to act in
the best interest of the network if they have a lot to lose.

While this may seem like a good thing, it actually centralizes power among those
who can afford to buy a lot of tokens.

For instance, to become a validator on the Ethereum 2.0 network, you would need
to stake a minimum of 32 ETH. This is a large sum for the average investor and
tech enthusiast.

Less secure
The Proof of Stake consensus algorithm is also more vulnerable to 51% attacks.
This is because it would only require an attacker to control more than 50% of the
stake in the network to fork the blockchain.

In essence, a “whale”, or somebody with enough capital to have a noticeable


impact on the market through large trades, can potentially become a validator and
have a significantly greater influence on verifying transactions.

Common questions

Powered by AI

Proof-of-Work (PoW) operates by requiring miners to solve complex mathematical problems to add new blocks to the blockchain. Miners compete to find a nonce that will result in a hash meeting the network’s difficulty criteria. The first miner to solve this adds the block to the blockchain and earns a block reward. This process is computationally intensive and consumes significant energy, posing environmental concerns and scalability issues due to low throughput. PoW can only process approximately 7 transactions per second for Bitcoin, as opposed to thousands with traditional payment systems like Visa . Additionally, the high cost of mining creates centralization tendencies, despite aiming for decentralization .

Proof-of-Stake (PoS) encourages decentralization by reducing the barrier for network participation, as it does not require costly computational equipment like Proof-of-Work (PoW). Participants only need to hold and stake cryptocurrency, allowing a wider array of users to participate as validators. This potentially diversifies the network, preventing centralization among a few entities as seen in PoW where substantial investment in mining equipment is required . Moreover, PoS may increase the number of nodes, enhancing the network’s resilience and security .

Proof-of-Work (PoW) is energy-intensive as it relies on competitive mining, requiring significant computational power. In contrast, Proof-of-Stake (PoS) consumes less energy, as it selects validators based on their stake in the cryptocurrency, eliminating the need for extensive computation . Regarding network security, PoW ensures security through substantial computational difficulty, whereas PoS leverages financial penalties, such as slashing, where a validator's stake is confiscated for malicious behavior. PoS does pose a centralization risk because wealthy stakeholders can exert more control, which can affect security by making a 51% attack feasible for individuals with substantial wealth .

Proof-of-Work (PoW) and Proof-of-Stake (PoS) address the blockchain trilemma differently. PoW prioritizes security through computational difficulty, but suffers in terms of scalability due to its energy demands and limited transaction throughput, processing only about 7 transactions per second. Its energy requirements also often lead to centralization among those who can afford costly mining setups . PoS mitigates energy costs and improves scalability by using less resource-intensive validation but faces centralization risks due to wealthier entities potentially controlling validator selection . While PoW remains more secure against certain attacks, PoS uses financial penalties to ensure security, though both face challenges in equally balancing those three components adequately .

The "nothing at stake" problem in Proof-of-Stake (PoS) arises because validators can theoretically validate transactions on multiple chains without penalty, allowing them to benefit from verifying conflicting versions of the blockchain. This creates a vulnerability where an attacker could support multiple forks, undermining consensus and making double-spending attacks more feasible . This problem challenges the chain's integrity and differentiates PoS from PoW, where extensive computational effort discourages forking due to resource constraints. Addressing this issue requires innovative solutions such as rigid penalties or slashing disincentives .

"Slashing" in Proof-of-Stake (PoS) systems acts as a deterrent by penalizing validators for malicious actions. If a validator is caught behaving dishonestly, such as verifying conflicting chain versions, their staked cryptocurrency can be partially or fully confiscated. This financial penalty acts as a strong disincentive against misconduct, as validators risk losing their invested stake, which is often substantial enough to outweigh any possible gains from dishonest activities. Slashing thus reinforces the economic logic that honest participation is more profitable and secure in the long term .

In Proof-of-Work (PoW), a nonce is a critical component as it serves as a random 32-bit number that miners alter with each hash attempt to solve the hash puzzle. The correct nonce produces a hash below the target threshold set by the network, allowing the miner to successfully mine the block. This nonce is pivotal because finding the correct one signifies proof of computational effort, providing the mechanism for ensuring network security and preventing fraudulent activities .

Centralized mining pools in the Bitcoin blockchain present significant risks under the Proof-of-Work (PoW) consensus. These pools consolidate hash power, which can lead to a situation where a concerted effort by a few large pools could result in achieving majority control over the network's computational power. This 51% attack scenario would enable the pool to authorize fraudulent transactions and double spending, compromising the network's integrity . While decentralization aims to distribute control, the economic efficiencies of scale encourage pool centralization, posing a threat to network security .

Proof-of-Activity (PoA) is a hybrid model combining aspects of both PoW and PoS. Initially, PoA uses a PoW approach where miners attempt to solve a computational puzzle, akin to PoW, to create a part of a new block. Then, stakeholders in the network are required to participate in signing the block, introducing the PoS element. This diversification allows PoA to reduce energy consumption compared to PoW while maintaining security mechanisms that leverage both computational effort and stake-in-network participation, attempting to bridge the limitations of both PoW's energy consumption and PoS's potential centralization risks .

Proof-of-Stake (PoS) ensures validator honesty through economic incentives and penalties. Validators must put up a security deposit or 'stake' of cryptocurrency, which they stand to lose if they engage in malicious activity such as confirming fraudulent transactions. This process, known as 'slashing,' reduces a validator's stake when dishonest behavior is detected, serving as a deterrent. Validators gain rewards by correctly validating transactions, providing an economic incentive to act honestly, as their potential financial loss (from slashing) is greater than any short-term gain from dishonest actions .

You might also like