Crypto Academy Week 12 - Homework Post for [@alphafx]

in hive-108451 •  3 years ago  (edited)

image.png
source

Hello professor @alphafx, it is a pleasure for me to give you an assignment again, I never imagined that the world of algorithms is so complex and at the same time so interesting.
I sincerely enjoyed doing this assignment, and I did my best.
I hope you like it!


It is appropriate to start the following post by talking about what consensus is, this means reaching agreement across many validators in a network, as opposed to how centralized transaction and transaction records work in a bank account. All validators (which could be thought of as the nodes that examine the blocks created by tokens and make sure they follow all consensus rules) in a network must agree on each new transaction record periodically. This network must also be able to tolerate validators that lie or send erroneous messages. The process of reaching an agreement, which is basically the consensus we defined above, should solve inconveniences such as the double-spending problem, which is when a cryptocurrency, consisting of a digital file, can be duplicated or counterfeited.

How many protocols exist to achieve consensus in a network?

There are several protocols for achieving consensus in a network, for example, Bitcoin and Ethereum currently use PoW, short for Proof-Of-Work, to achieve consensus; a protocol where network nodes compete with computer power to resolve cryptographic puzzles and reach consensus. Many other protocols in the broader transaction and transaction log space have implemented some form of Byzantine Fault Tolerance (BFT). BFT validators send messages back and forth, and use a voting process where a new transaction log is confirmed if more than 66% of validators agree with that history, is considerably faster and cheaper than using PoW, but sacrifices decentralization to achieve those features.
As a decentralized alternative to BFT arises the main topic of this publication: Stellar Consensus Protocol (SCP). The best way to understand this topic is to know and buy its features from PoW and BFT.

What are its main characteristics?

The first characteristic is an open or closed membership, in other words, they are those who can participate in the consensus process. In PoW terms, anyone with the ability to mine could participate in the consensus and miners, equivalent to a star, can join and leave the network without impacting the consensus. In a BFT environment there must be a recommended list of validators, defined by a central authority, company behind the protocol, among others; but a person can only participate in a consensus if that authority allows them access to this group. This requirement for a list of recommended validators means that BFT grants you this centralized closed membership system. Even if you have a million nodes in the validator list or if you remove the zone validators from the central authority, it would still be centralized because there is a list of recommended validators. In SCP, there is no list of recommended validators chosen by a central authority, instead, each validator decides which other validators to trust, and their list of trusted validators is called: "quorum sector". The quorum sectors of each validator overlap to form a network-wide consensus on a transaction without the need for a centralized authority to decide on the list of validators, thus creating a membership network that can be implemented by any validator, because there is no higher authority. To summarize this feature quorum sectors allow open membership and thus decentralization.

The second characteristic is security according to what is called: FLP impossibility test. In distributed asynchronous systems, such as SCP, a consensus mechanism may prefer at most two of these three properties: security fault tolerance, security and liveness. This is a proven result that any distributed consensus system must sacrifice a preference for one of these features, fault tolerance means that the system can survive the failure of a validator at any time, many consensus protocols choose this as one of their two preferred property protocols. One bad thing that will never happen is an accidental fork, this means that, if the network cannot agree on its transaction log, it will not fork and the validators will not create two different ledgers, the network will stop progressing and you would have to manually log in to try to fix whatever is happening. Liveliness is a guarantee that something good will happen, the good thing is the closing of the ledger, this means that the network will always close, and this in turn means that the validators can diverge into different ledgers causing an accidental fork in two paths. To summarize, the difference between security and vitality, is that you cannot be sure that a distributed system will not fall into an accidental fork; or security, and that it will continue to progress, so you must choose which of the two options you wish to forgo.

The previously mentioned PoW, favors vitality over security, meaning that if, for example, the internet were to collapse in China, from the rest of the world a fork in the BitCoin blockchain would occur. Miners in China would continue to build on a blockchain, and miners outside of China would fork and create their own ledger with possible forks. BFT protocols vary in their preference for security versus vitality, but SCP favors security in case of an accidental fork and stops the progress of the network until a consensus can be reached, this is a crucial feature in the minds of central banks and in turn this is another feature of this protocol.

Its fourth feature would be low latency, or its short speed between transactions. For example, in Bitcoin the implementation of PoW, makes the computational puzzles involved in mining a block take approximately 10 minutes. And because Bitcoin favors vitality over security, you must wait for 6 blocks to be confirmed before you can be certain that your transaction was included. This causes that the times of transaction are in the range of 60 minutes. Unlike this PoW, there is no mining process in BFT and SCP, it is just a message that goes through a voting process. Your message goes through because transactions are confirmed much faster every 3 to 5 seconds. And because these protocols favor security over vitality you don't have to wait for multiple ledgers to be confirmed. This preference for security essentially shaves 6 to 12 times the transaction time.

Finally, it is appropriate to name its asymptotic security, this means that no amount of computational power can overcome the network. PoW does not exhibit asymptotic security as an irrational attacker or someone with external incentives could overcome the PoW consensus with what is called a 51% attack. If 51% of the compute power in the network is controlled, then we could drive a consensus. But in BFT or SCP, an attack using computing power is not possible because solving cryptographic puzzles is not a component of the consensus, but validators sign their approval on new ledgers using their private keys. In BFT, more than 66% of validators would have to associate to take over a consensus, but this is unlikely and this is how the central authority has control over which validator are permitted on the validator list. In SCP, there is a complex network of overlapping quorum sectors that make it almost impossible for even a large majority of nodes to try to associate to control the consensus. An attacker could create thousands of validators and, unless the majority of other validators went so far as to add them to the quorum sectors they would not be able to affect the consensus. In PoW, that trust is under the hope that one group will not be able to control 51% of the mining power.

Advantages and disadvantages

Stellar offers different advantages within its system, mainly we highlight that its operations are much faster than those of other platforms. Another advantage is that its commissions are really low. We can also mention its extensible protocol and that it does not use a mining system for its verification process, in addition to the fact that the platform offers a high scalability. However, one of the reasons why this project caught the attention of investors is because of its resemblance to Ripple; that is why they rushed to invest expecting a very high profitability. On the other hand, it is not decentralized either, currently more than 90% of these are in the hands of the foundation. This may cause distrust in the project.

Conclusions

To recapitulate, the consensus protocol provides open membership and therefore emerges as a decentralized alternative to BFT; it closes transactions in three to five seconds; it prefers security to vitality and is not susceptible to PoW attacks.


Thank you for this assignment professor @alphafx ! I am very grateful to you and all the teachers at Steemit crypto academy for the intellectual growth you have brought to us.
Forever grateful.


a.png

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE STEEM!
Sort Order:  

Good extensive work, lacking clear headers toexplain concept like quorum, qurum slice, federated voting, etc
Task satisfactorily done

Parameterrating
Presentation1/2
Content3/5
Originality2/3
Total6

Thanks for participating