Blockchain Consensus — What You Should Know

Katalyse.io
The Startup
Published in
6 min readAug 8, 2018

Blockchain Technical Series (5 part series — PART 2)

Let’s start with the fundamental understanding of the term “consensus”. To reach consensus simply means to arrive at an agreement about something. To achieve a consensus, usually, people would first analyze whatever thing (be it a material thing or an opinion) they are looking to agree on from all angles, test it and finally arrive at a common conclusion.

If there is ambiguity, you may choose to do more tests in order to accept it or not. Sometimes, you may also ask a person you trust to do the prodding and checking for you. Since we are human beings, people may choose to influence the consensus by either telling lies or by persuading others to accept their side of the story.

As you can see, “trust” can be problematic and these challenges can negatively influence consensus making. Blockchain solves this problem by enabling you to arrive at an agreement in an independent way. So, how does Blockchain reach a consensus?

Image: rawpixel.com

Blockchain Consensus

Here there are two things involved: Consensus and Algorithms. When you combine these two concepts, you end up with a set of rules and series of steps that will enable you arrive at largely accepted decisions among a group of individuals.

Consensus algorithms are not only a vital part of the Blockchain technology but also the recipe for the network rules that guide all sequence of events. Simply put, the algorithm lays out: when “X” happens, then “Y” will happen, and so on. This way, consensus algorithms validate, authenticate and keep track of the transactions of a block. Transactions come in many kinds. They include; financial transactions, for instance with Bitcoin, access to dapps, swapping ownership rights, trading data and much more.

Consensus mechanisms play a vital role in preventing double-spending issues. In simple terms, double spending can be likened to sending a photo digitally. You send a copy and you remain with the original picture. Subsequently, two people end up with a similar picture. Now imagine if this could happen in the crypto sphere! People would make the same transaction severally, become wildly rich and eventually, the entire network would get destroyed. Consensus mechanisms come in handy in preventing this fraud.

Next, let’s examine the common consensus algorithms in Blockchains:

Proof of Work (PoW)

The PoW is the most common consensus evaluation method. The special thing about PoW is that it does not require all nodes (parties on the network) to submit their specific conclusions for a consensus to be reached.

Instead, it uses encrypted transactions in a data block (hash functions) to create situations (mathematical equations which are hard to solve but are easy to verify their correctness) where only one participant within the network is allowed to share their conclusion about the information submitted (solution to the mathematical problem). Other participants within the network only verify the conclusion. The hash function is programmed to reject false information.

In Bitcoin which uses PoW, the party who publicly verifies the correct answer is rewarded with newly mined Bitcoins. The process of finding and verifying the valid and correct hashes is called Bitcoin mining. Giving incentives to Bitcoin miners increases wider interest and participation. A big network of engaged members creates a robust and safer Blockchain where you can conduct your transactions with ease and anonymously.

However, the downside of PoW is the huge energy costs of computing. Mining machines consume a lot of electricity and are considered environmentally unfriendly. Also, to become a participant, you must have a stake in the network.

Proof of Stake (PoS)

PoS systems use algorithms in place of hash computations thus cutting down on energy costs. They are also considered more environmentally friendly. They use simple digital signatures to validate proof of ownership or stake. The system then chooses a participant to verify the new transactions in the database and create a new block.

The selection criteria is based on participants holdings or stake. The more stakes you have the higher your chances of being picked and vice versa. PoS also gives incentives to help build a huge community of enthusiasts.

A good example here is Peercoin. It uses PoS and rewards the successful validator with transaction fees as opposed to new ‘minted’ coins. Minting is creating coins in PoS just like mining in PoW. While rewarding participants with higher stakes will encourage participants to acquire more stake, it also increases the risk of centralization as the rich keep getting richer and having more control.

Delegated Proof of Stake (DPoS)

DPoS systems use what is called representative democracy. Participants vote, using their coin stakes, for their representative who will verify the transactions in the database and receive newly minted coins. The representative then shares the coins with the voters based on how many coins one used to vote relative to the coins used by other voters who voted for the same representative.

DPoS offers the flexibility of multiple voting rounds and participants can change their vote and vote for a new representative if they feel he/she has a better reputation. The DPoS algorithm also employs a feature called shuffle equation which makes the process of choosing representatives a little complex reducing the risk of system transaction interference.

DPoS also reaches consensus much faster than PoS or PoW because it has a small pool of delegates to choose from. This, however, poses the risk of centralization because representative delegates could form cartels or secretly collude. Further, it is designed to give more voting rights to persons who hold more coins (just like in PoS) and this can transfer more influence to fewer stakeholders increasing the risk of centralization.

Alternatives

There is more hope! New Blockchains are springing everywhere and creating new consensus algorithms. Some are born from adjustments made on existing algorithms while others are entirely new. We will briefly examine three.

Directed Acyclic Graphs (DAG)

Also called the Blockchain killer, this consensus algorithm does not run on Blockchain and claims unlimited scalability because of its super low transaction costs. It is still in experimentation with a few projects like Nano and IOTA already using it.

Proof-of-Authority (PoA)

In this algorithm, the network admins validate and approve the transactions. It is highly centralized but also very efficient. This could work for private Blockchains where members know and trust each other.

Practical Byzantine Fault Tolerance (PBFT)

Byzantine General Problem occurs inherently in all decentralized system because they accept transactions from all parties in the network even though some parties maybe up to no good. One way of dealing with this problem is using PBFTs.

There are three Blockchains that rely on PBFT; Hyperledger, Ripple and stellar. Under PBFT a consensus decision must be reached based on all decisions of participants in a given network, made individually and anonymously.

Conclusion

The importance of consensus algorithms cannot be overemphasized. They help prevent double spending, build trust and keep the integrity of Blockchains.

With anonymity and absence of centralization, Blockchain systems have their own checks and balances to create and maintain consensus. Already, PoW, PoS and DPoS have had their fair share of success. They incentivize their members for transaction validation, which keeps their Blockchains secure.

It is clear, however, that the top three consensus models have their inherent risks and not one is perfect. Hence more and more models which are being created or improved to keep the decentralization ethos of Blockchains.

Keen to find out more about FundYourselfNow? Join our crowdfunding revolution conversation on our Telegram group, or follow us on Twitter.

This story is published in The Startup, Medium’s largest entrepreneurship publication followed by 356,974+ people.

Subscribe to receive our top stories here.

--

--