nakamoto

Blockchain consensus

This will be a very layman introduction to the concept of blockchain. It won’t go into too many details because the target audience are the non-technical people which is the majority of the users today. We’ll start off by introducing what the general idea is and how we may implement it. In the next chapter, we’ll describe a new way to implement it.

What is a blockchain

Blockchain is a variant of a one-way step function in the sense that we’re trying to make a step function where it should be easy to make a step forward, but very hard to make a step backward. The linearity of steps is what enables the society to march together on common grounds in the digital world. To my knowledge, no such function was available until Bitcoin. Bitcoin was the first to implement it and it used these steps to introduce a globally shared accounting system also known as a ledger. We won’t be using the standard blockchain terminology of a chain of blocks, we’ll instead refer to these as a sequence of steps as it might be simpler for someone not yet familiar with the concept.

How to make a step

We need to find a way to agree on what the next step is. An easy way to do that would be to assign administrative powers to an individual who shows the next step and everyone follows it. But that’s very centralized, gives a lot of power to that individual and is very easy to attack and prevent new steps from being made. We don’t want the society to stop marching forward or to follow the orders of a single individual. The administrator could also easily lie and show different steps to different people. This is how central information works today. A website like facebook could be serving different data to different people for all we know. I don’t think there’s anything wrong with this, the service comes with this trust assumption and everyone can opt-in to use it. But to make a step together, we’d want to ensure that the observed step is the same for everyone without the need to trust any single individual or an entity.

We have to agree as a society on what the next step is. This is a hard problem. We obviously can’t have voting in real life on what step to take as this would be too slow and, more likely than not, manipulated. We’d also have the problem of deciding who proposes the possible steps. We want to avoid giving power to an individual or a selected group and instead find a more inclusive solution. Is there a way to agree on a step where anyone can propose it while also guaranteeing progress in case of adversaries?

Blockchain consensus mechanisms describe different ways in how a new step is made in a decentralized way. There’s been a long-standing debate around PoW and PoS based consensus with many advocating one over the other. We’ll try to describe one possible way of building a one-way step function based on Proof of Stake that achieves some of these properties.

Proof of Stake

Let’s imagine scarce resource called a coin lives in our one-way step function. This isn’t US dollar or any other known currency or asset. It’s a resource created by this function that’s totally unique, only available inside this function and there’s only 10 million coins that will ever exist. We can give this resource around to people. For simplicity, let’s assume we somehow managed to distribute these 10 million coins fairly among people whose vast majority are honest and can be trusted. We can now imagine that this step function we’re creating is its own digital world where the coins are the citizens living in it. Each citizen has a right to vote. Since the steps are public and the data about coins is seen by everyone, anyone can see these citizens and confirm who they are. We know a link from a citizen to a real life identity exists, but this identity might not be known to others. The main idea to reach consensus is that we have either a single citizen or a group of them vote on what the next step is. How do we select who’s going to vote on a particular step? We don’t want them all to vote on each step because this would be too slow to communicate. We’d want to select a sample of them that would vote on the next step. This way, it’s a perfect democratic system for these citizens. This idea works if the vast majority of the citizens are honest. We can now do some form of democratic voting on the steps. What exactly is a step? We can define it to be a set of transactions where these coins are being moved around. The citizens voting will only vote on a step if the set of transactions proposed has been authorized by the coin owners. Great, if we have honest citizens this should work. But who decides on the set of transactions that will be at each step? We can have a fair lottery between the citizens that are a part of the voting process for a step and one of them wins the ticket to propose the set of transactions. We now have a working transaction system as long as the majority of the coins are in honest hands. Anyone observing these steps can check if the transactions have been correctly authorized to confirm there’s no shady business going on. We have constructed a one-way step function where a step is common knowledge available to everyone. We will practically never have two different steps proposed if the supermajority of citizens are honest and a random subsample agrees on a single step.

How well does this work? Well, it depends on the adversarial conditions. Remember that the citizens that perform the step can be seen by everyone. What happens if the majority of the citizens get duct taped on the tree or disappear i.e. they stop moving/interacting with this world? It seems like we wouldn’t be able to make a new step if that were to happen. What if the owners of the coins have political incentives in real world that are in conflict with what’s good for this new digital world we created? Maybe they’re willing to sacrifice their monetary value to cause havoc when they’re on their death bed. Another important thing to note is that we can see who voted at each step and a real life entity could decide to punish a few of the citizens in real life if they didn’t like some aspect of their vote i.e. we think they should never have voted for such a step. There’s also a form of circularity where the current set of voters votes on the next set of voters. It seems like we were able to build a working system, but it may still be prone to being attacked when confronted with a powerful adversary. The key properties of this system are that the election results are public, the citizens are well defined and known in advance and they vote on who will be included in the voter set.

Continue to Nakamoto consensus.