Algorithms of PoS
Proof of stake algorithms can be categorized by different factors, which we explain in the following paragraphs.
Byzantine based vs. Chain based vs. Committee based PoS
The central feature of a Proof of Stake system is to select a node that creates a block. There are three major ways to do this.
Chain-based PoS is the earliest idea of proof of stake. It simulates the Proof of Work algorithm where a hash puzzle needs to be solved to determine the next block producer. But instead of solving a puzzle over and over by increasing the nonce as quickly as possible the balance a node holds determines the threshold.
Coins that used a chain-based PoS: Peercoin and Nxt.
Committee-based PoS is another approach to selects block producers (or validators) from a given set of candidates. Usually, the order and the validators are chosen from a previous state of the blockchain, including each candidate’s stake. Once the committee agrees on the order, block producers create blocks in a round-robin-like fashion.
Byzantine fault-tolerant (BFT) based proof of stake consists of two stages:
1. block producer selection and
2. finalizing.
The first stage includes either a committee-based algorithm or a chain-based algorithm. It is also possible to apply a hybrid PoW-PoS scheme.
In the 2nd stage (finalizing), validators vote for each block by signing it. If at least 2/3 of the validators have signed a block, it is considered irreversible and thus finalized.
Deposit vs. holding
Since PoS depends on the funds users hold, it is necessary to agree on which funds are taken into account when selecting a block producer.
The simplest way would be to include all holders (or rather addresses) of a particular cryptocurrency. The actual miner or block producer is selected by a random choice like “follow the Satoshi”. The problem here is that many users who are not interested in participating are not aware of their selection. Without further measures, this would hold up the whole network. A remedy could be to ignore addresses that didn’t respond, but this creates additional complexity.
Another concept is that of registration with a smart contract. Users who want to participate in the PoS consensus algorithm need to register and deposit a certain amount. The probability of getting selected as a miner depends on the deposit height. The more a user stakes, the higher is the probability.
Penalty vs. no penalty
In PoW, unruly behavior by miners is punished by the loss of the consumed energy. This happens inherently because if a “wrong” block is ignored by other miners, the time and energy used is wasted. In PoS there is no such inherent mechanism. That’s why the network needs to agree on punishments or no punishments for wrong behavior.
If a block validator doesn’t follow the protocol or doesn’t reliably respond after being selected as a block validator, he could either be punished or ignored. A punishment could be to burn his deposit (stake). While punishments create more security, they add, in turn, more complexity to the whole network. It also increases the risk for block validators to accidentally losing their staked funds. It could make them also vulnerable to denial of service (DoS) attacks.
Coin age vs. no coin age
In the basic PoS model, all coins have the same influence. Let’s consider an example. If user A holds 10 BTC and user B another 10 BTC, both users have the same chance to be selected as a block validator. Here, it is unimportant how long the coins belong to a particular user or how long it hasn’t been moved. An alternative is to include the coin age into the calculation of the voting-weight. The longer a coin remains on the same address, the higher its weight is. Let’s assume that user A and B have 10 BTC each, but user A hasn’t moved its coins for a long time, and user B has received the coins just shortly. Now user A would have a higher probability to get selected as a block validator than user B. Once the funds were used for validating a block, the coin age is set to zero. It is also possible to cap the influence of the coin age.