Beyond Consensus — Part 1

“What is your consensus algorithm?” This is the most common question we hear when meeting people working in the blockchain space. It’s used as an icebreaker, like asking someone what they had for breakfast or what they think of the weather, and in our experience it’s just as irrelevant. This is because the phrase “consensus algorithm” exaggerates the importance and complexity of one narrow aspect of blockchain systems, not to mention the intelligence of the person asking the question. Take proof of work for example, a popular consensus mechanism. At the end of the day, proof of work is dead simple. It’s nothing like beasts such as Paxos, which we would call a Real Consensus Algorithm, what with all its carefully-thought-out phases, message sequences, roles, and edge cases.

Even when comparing proof of work to traditional consensus mechanisms in the real world such as voting, people are often surprised by how systems like Bitcoin and Ethereum actually work. To illustrate, consider the following analogy. Imagine we created a new country, and rather than periodically holding a vote to elect a president and painstakingly counting those votes and carefully checking for voter fraud, we instead decided to choose a new president every 14 seconds at random. Each new president might choose to do nothing or might launch all the nukes at once. Since the country would pretty quickly self-destruct, most people wouldn’t call this consensus. They would call it ridiculous and wonder how such a system could possibly function.

Fortunately this ridiculous “choose randomly” strategy works fine in blockchain land, because this step isn’t actually where consensus occurs. And the magic doesn’t come from consensus anyhow, nor from how we decide who gets to add a block or what they decide its contents are. In fact, the lucky creator of a block is pretty limited in what they can do. The real magic of systems like Bitcoin and Ethereum lies in a combination of several things:

  • Public-key cryptography. Only the owner of an address can use its funds, and it’s trivial for any node to check the validity of a transaction. This means for instance that neither a block creator nor an attacker can inject forged transactions.
  • The assumption that the majority of nodes are correctly executing the same protocol. In other words, protocol designers can decide arbitrarily whether certain behaviors are acceptable or unacceptable. Any behavior that doesn’t adhere to the protocol will be rejected by the network. But if this assumption breaks, we can end up with undesirable consequences such as permanent forks.
  • Alignment of incentives. Mining is encouraged through block rewards, and block creators are incentivized to include valid transactions due to transaction fees. But if they felt like it, block creators could be very picky about which transactions they include, or include none at all. But they can’t launch nukes.
  • The fact that proof of work connects the virtual world with the real world. If information was stored in a spreadsheet or a SQL database rather than a cumbersome append-only data structure linked by one-way cryptographic hashes and proofs of work, then it would be easy to generate a different version of history, and who’s to say which version is correct? But with proof of work we must expend scarce physical resources to create alternate histories. Whenever multiple possibilities present themselves, we merely pick the one with the most proof of work. It’s overkill to use the term “consensus algorithm” for this simple rule of “pick the biggest.”

In fact, some of the best innovations in the blockchain space haven’t been in the area of consensus, but instead came from things like smart contracts (think Ethereum) or bleeding edge cryptography to protect privacy on public chains (think Monero and Zcash).

To reiterate, consensus is just one component of a blockchain system, but there are several others that are critical yet tend to be overlooked such as public-key cryptography and alignment of incentives. Only by combining these different pieces do we end up with a useful system. As a side note, all of these components are explained extremely well in the original Bitcoin white paper, and it’s a nice short read. Even if you only have time to read the abstract, go do it. It’s well worth it. And then read on to part two of this blog post.