Making (non)sense of blockchain
Tags: blockchain
Published: 2019-02-28 15:30:04

---
title: Making (non)sense of blockchain
published: true
description: 
tags: #blockchain
---

Now that the hype around blockchain is dying out, it seems like a good time to give the technology a good objective look.

Many of you have probably heard of at least one absolute bullshit way in which some company has tried to force 'blockchain' into its technology stack. It may come to no surprise that [the success rate of blockchain is looking rather abysmal](https://www.theregister.co.uk/2018/11/30/blockchain_study_finds_0_per_cent_success_rate/). The industry was suffering from a clear case of "if the only tool you have is a hammer, every problem looks like a nail". Or, in this case, some people got really exited about hammers.

What isn't helping is that there are a plethora of incomplete, incorrect or overdetailed explanations about blockchain. Many have been about as useful as the [humorous nonsense generated by botnik](https://www.youtube.com/watch?v=tBRWJzAjkjk).

Considering this, I thought it might be a good idea to give a high-abstraction level overview of what blockchains are (not).

### Basics

A blockchain is a singly linked list with extra steps: every link has a hash of the block it links to, ensuring that blocks (elements) in the tail *cannot* be changed without invalidating the head.

That's pretty much it.

### The point

As you probably know, blockchains are primarily used to ensure trust. If you trust the head of a blockchain you can verify the validity of the tail.

So far, nothing is stopping an unscrupulous party from just changing the head: a block in the tail can easily be faked by popping a few values, changing an element, pushing the values back, and recomputing the hashes.
That is why pushing a block to the chain generally incurs some kind of cost. This way one can ensure the longest chain is the one that has had most investment, and is therefore probably "the right one".

As you might have guessed, this estimation of "the right one" only works if at all times, the expenditures made for updates of the bonafide chain is greater than expenditures made into updating a fraudulent branch. If not, the fraudulent branch may overtake the bonafide one and be identified as correct.

### Push costs

So what are these costs that can be associated with pushing new blocks on the chain? 

There's a few, the most infamous method is proof-of-work. Proof-of-work requires finding the inverse of a hash. This takes a lot of compute power and therefor electricity. When people mention environmental concerns as an argument against blockchain, this is what they really mean.

There is also proof-of-burn and proof-of-stake. I personally am not convinced by these algorithms. My knowledge of blockchain is limited to cursory academic literature review so perhaps I am missing something here. They require the destruction of some kind of virtual value stored inside the chain for the addition of a new block to the chain. This creates a situation in which a blockchain verifies its own validity.

In theory you could also use FIAT currency expenses as costs for pushing blocks. A donation to a charity for instance. In practice, this requires a trusted party to verify validity of FIAT payments, and if there is trust, there is no point to blockchain. At least, not beyond hiding illegal activities.

### Unique pushes

In some cases, adding blocks to the chain can be tied to the destruction or exchange of unique or limited items. For instance, the exchange of a physical item may be required to add a block to the chain. In this case, pushing blocks on a 'bad' chain becomes simply impossible, because the item required to do so is already spent.

Unfortunately it's rather uncommon to have such unique items involved in block creation.

For instance, a group tried to use blockchains to verify the source of diamonds. In this case, the physical exchange of a diamond (or rather, a digitally signed agreement from both sender and receiver) can be made a requirement for adding a block to the chain. The validity of such a system depends on how well a diamond can be uniquely identified, lest the same chain be used for different diamonds.

### Relation to cryptocurrencies

With cryptocurrencies, blockchains are primarily used to solve the double spending problem. Double spending occurs when the same coin is spent multiple times, either maliciously or by accident. This can happen in a distributed system when there is no absolute order of payments.

## Conclusion

I hope this article has given you a bit of insight into blockchains, what they can do, and what they can't. If there's enough interest in the subject I will create a flowchart to check if blockchain is the right technology for a certain problem. Spoiler alert: probably not.