Nothing at Stake / Costless Simulation

Published by Mario Oettler on

The most basic attack of a PoS consensus system is called nothing at stake attack, also known as costless simulation. Suppose we have a blockchain with two branches A and B. A block producer evaluates the success likelihood of branch A to be 0.9 and branch B to be 0.1. The block reward is 5. The following figure illustrates the situation.

If a block producer has to decide which branch to follow, he has three options:

  1. Follow branch A. The expected reward r is 0.9 * 5 = 4.5
  2. Follow branch B. The expected reward r is 0.1 * 5 = 0.5
  3. Follow branches A and B. The expected reward r is 0.9 * 5 + 0.1 * 5 = 5

The rational decision would be to choose option three and work on both branches.

The third option is possible because all coins are available on both branches after the fork. This allows the block producer to stake his coins on both branches and create blocks.

The problem with this is that no chain would contain the highest stake. Consequently, the network would not come to a consensus on which branch is the canonical one.

In a PoW mechanism, the miner can only mine on one branch. If he wants to mine on two branches, he would have to split his hashing power. The hashing power dedicated to the losing branch would be wasted.

A solution would be to punish block producers that create blocks on conflicting chains.