What’s a blockchain?

And if they don’t love me now, they will never love me again, but they could never break the chain

What is the blockchain?

In Web2 databases, information is stored in one location, usually in a central server of the company who owns it. Think of Amazon or Facebook. They administer their own databases in secret, only making specific elements public. Whoever controls this database has supreme power over its data. If Facebook wants to delete or silence certain contents, it has all the power to do so. Web2 databases are centralized, where the owner and only the owner is in full control.

Contrary to Web2 databases, blockchains function as decentralized databases. Every participant of the blockchain has a copy of all the data. The source of truth is whatever the majority of blockchain participants support. Since anyone can participate in validating the blockchain, it functions as a super-democratized system of truth and data. If thirty computers say that an apple belongs to Dylan, and one says it belongs to Dan, there is no doubt that the apple belongs to Dylan. People trust that the majority of nodes contain the truth.

Imagine trying to change the bible. You could amend a passage in your own copy, but it would be easy for someone to point to the millions of other copies on earth to show that your version is fake. If you wanted to actually change the bible, you’d have to access and change every single copy on earth – an impossible task.

Two Types of Blockchain

The blockchain has exciting new potential applications, both for organizations internally and for individuals. 

One use for blockchains is to grant everyone access. This works well for things like cryptocurrencies. Anyone can buy or sell Bitcoin, contributing to the blockchain. Since access to editing these blockchains is entirely open, these are referred to as permissionless blockchains.

Another type of blockchain restricts access to a small group of users. This might be done for supply chain management between a handful of companies. In these situations, a shipping company may not trust the supplier of coffee beans, the roaster may not trust the shipping company, and the store may not trust the roaster, but in a well-architected ‘permissioned’ or ‘private’ blockchain, each entity can store its relevant documentation about its piece of the supply chain in an immutable ledger. 

They can then share only the relevant information to other suppliers in the chain to ensure quality, quantity, and freshness are maintained throughout the entire process to the customer. 

Why does the blockchain work?

Imagine a bug caught in amber.  When it is first trapped, there’s not much amber around the fly. Over the following weeks, months, or years, the tree continues to ooze sap, trapping pine needles, then leaves, then bark, and maybe later even other insects. As time progresses, the initial ‘layer’ of amber around the mosquito is buried quite deep with dozens of other layers and debris surrounding it.

The blockchain works along similar principles. Each piece of information in the database exists in a ‘block’ – think of it like an insect or pine needle preserved in a layer of amber. Each block of information is verifiable, and timestamped – just as anyone can look at an insect in amber and see what kind of insect it is, and also tell how long it has been in there, relative to the other layers.

Tampering with the outermost layer (i.e. the most recent block) is somewhat straightforward since it’s not trapped very deep. Removing a pine needle from 5 layers deep, however, is nearly impossible without indicating that the amber has been tampered with. This is also true with blockchain. It’s essentially impossible to change the information in older blocks without it being obvious to everyone else that you’ve done so.

This makes blockchains an extremely secure way to store information over time, that everyone can agree is authoritative.

Introduction to Encryption

Encryption is the process through which information is converted into a form where it cannot be read by intercepting parties. This is done by applying an algorithm, which is essentially a process, applied to a piece of data. For example, to encrypt a word, you might change each letter to its next letter. This is known as a Caesar Cipher.

Encryption used in modern computing is more mathematical, applying complex mathematical formulae to the text inputs. This takes advantage of advances in computational power and makes it harder to break the cipher.

In addition, even though services like WhatsApp encrypt their messages, it is not just messages sent between humans which end up encrypted. In fact, data which is sent solely between computers like timestamps, amounts of money in your bank account and even code can be encrypted to stop hackers from intercepting or interfering with it. If something is encrypted, while hackers can change it to something nonsensical to stop it from arriving, without knowing the encryption method they’re unable to alter or read the data.

Hashing

Hashing is one type of one-way type of encryption. A hash is a mathematical encryption algorithm that essentially turns data into an encrypted form, all of which are the same size. 

Imagine you have two bananas and an orange. If you put them into a blender, you will be left with a smoothie. If you give a drop of that smoothie to your friend, it is impossible for them to turn the smoothie back into two bananas and an orange. However, if they have two bananas and an orange themself and put them in a blender, they will get an identical smoothie. They can then compare the two smoothies to ensure that they are the same. 

Hashing functions work similarly. They take any input of words or numbers and generate a unique output. So you can feed words and sentences like “hello”, “¿Cómo estás?” or “Voulez vous coucher avec moi?” into the hashing algorithm, and get a unique, but consistent output.

Let’s look at a little visual illustration below of the most popular hashing algorithm, SHA256.

When we feed the word “rice” into SHA256, we get the following output:

Original wordHash
rice209f76418ece7c936b65ff4777a578d860f762c37ad6c7f08f5826242199ef51

The same input will ALWAYS produce the same output. But, a slightly different input will generate a vastly different output.

Original wordHash
rice209f76418ece7c936b65ff4777a578d860f762c37ad6c7f08f5826242199ef51
lice8c5d8b0ed1241b2de50a0f3359128afe96bdefd335faa2c0e7344e115d33f92a
dicee1e025805cd63af3eaf1de7c010a537df1fa24009c5d332f3a068cd382e46ca7

However, you can never go from hash back to the original input.

The most popular application for hashing is actually with passwords. Companies like Facebook don’t actually store your password – that’s too risky. To login, your computer only sends the hash, not the actual password. Facebook only stores the hash – the nonsensical long string of characters you saw above. It then compares the hash that you sent to the hash it has saved. If Facebook is hacked, the hackers can’t figure out your password – they only see the hash! 

How is hashing used in the blockchain?

Hashing actually has multiple functions in blockchain technologies. 

First, it’s vital to secure your assets. As you probably know by now, the only thing that Jenny needs to unlock her bitcoin is her private key. It functions like a key to a super-duper secure safe. Only with the private key can she access her funds. When Jenny attempts to make a transaction, her private key is hashed to her public address, and her ownership is confirmed. 

To send bitcoin to Martha, Jenny finally needs Martha’s public address, and Jenny can pay back Martha for all the martinis they had last Friday night.

Considering blockchain’s reliance on encryption, there are countless other areas that hashing is implemented to ensure security and privacy on the blockchain.

Consensus Mechanisms

So – a blockchain exists as a series of blocks of data, which are verifiable but unmodifiable. But who is taking the time to keep the system alive and well? For blockchains to work, it’s essential that people spend the time and money required to validate the network.

This is where ‘consensus mechanisms’ come in. They are aptly named: these are mechanisms for proving consensus about the data on the blockchain. To use the earlier analogy, consensus mechanisms are the processes people use for verifying that their smoothies have the same fruit in them.

All blockchains require consensus mechanisms, and there are a number of different approaches to creating them. The two most famous are ‘Proof-of-Work’ – used by Bitcoin, and ‘Proof-of-Stake’, now used by Ethereum and most other newer blockchains.

Proof-of-Work

The two main consensus mechanisms are Proof-of-Work and Proof-of-Stake. They are different ways of achieving the same goal – incentivizing people to spend the time and computing power to keep the blockchain alive and well.

Proof-of-Work works by requiring participants – known as miners – to solve complicated math problems to verify transactions on the blockchain. 

These math problems are very expensive by design to keep malevolent actors at bay. Attacks on the blockchain are disincentivized, since it takes a lot of computing power and energy to mine a block.

In theory, if you had over 50% of the computing power in the network, you could proclaim yourself as a billionaire and send tons of faulty transactions to yourself. But, because mining is so, so expensive, such fraudulent activity is effectively impossible. And even if it was, as soon as you’d changed the ledger, people would realize – and lose trust in the currency. Since the only thing giving crypto value is trust, hacking large cryptos is impossible and uneconomical.

However, since energy is expensive, validators need a financial incentive. This is created through cryptocurrency rewards. Anyone who dedicates computing power to mining will be rewarded with that blockchain’s currency for doing so.

Proof-of-Stake

The other major consensus mechanism used is Proof-of-Stake. This was invented as an alternative to Proof-of-Work when people realized the financial and environmental costs of using so much energy to validate the blockchain.

Proof-of-Stake instead requires participants in the network to ‘stake’ some of their coins – to put them up as collateral. In return, they are entered into a pool of people. One (or a handful) of these people is randomly selected to run the computer operation required to validate the block in the chain. Because they have skin in the game – their money is at stake as collateral – it can be safely assumed that they will not tamper with the block, otherwise they risk losing their ‘staked collateral.’

Proof-of-Stake is generally considered to be a superior, more efficient and environmentally-friendly alternative to Proof-of-Work. However, the biggest blockchain in the world – Bitcoin – runs on Proof-of-Work. With a 10+ year successful track record of never being hacked, it seems unlikely that Bitcoin will switch to Proof-of-Stake. But most new development and activity in the blockchain space is occurring on Ethereum or other chains that use proof-of-stake.

Uses of blockchain

There are many different potential uses of the blockchain that capitalize on its many advantages. In fact, the blockchain is expected to become the primary mechanism for widely used databases as Web3 rolls out and becomes increasingly popular.

One category of things which are likely to be added to the blockchain are things which want to be made resistant to tampering. Examples of these include digital currencies, real estate ownership and intellectual property ownership records.

Another category of things which are likely to be added to the blockchain are things which need to be kept private. Examples of these include personal information data, medical histories and mental health records. 

Benefits of blockchain

One of the benefits of blockchain is that it is effectively impossible for any agent to make changes to a database without those changes being visible to everyone. In Web2, you would only need to access and edit the database in order to change its elements. This means that theoretically, if you had access to your bank’s database, you would be able to move money from someone else to yourself without their permission. 

Proponents of blockchain say that it’s safer because, in the blockchain, it is impossible to change other people’s blocks once they are in the chain. However, given that modern banking databases are safeguarded with consistency reviews, one-time-passwords, two-factor authentication and complicated encryption, your money is pretty safe in the bank too.

A second benefit of the blockchain is that interactions can be conducted anonymously. Instead of having to give a third party your name, so they can store it alongside your money, the database in the blockchain only relies on where the blockchains exist digitally to identify them.

Finally, it cuts out the third-party entirely. This means that even if you live in a location where a trusted, stable bank doesn’t exist, you can still rely on the safety of your money. Moreover, you don’t need to pay transaction fees or rely on the bank not to lose your money on poor investments, cutting out the middleman.

Drawbacks of the Blockchain

However, there are also some key disadvantages to blockchains. 

With a centralized database – like those of a bank – the government is able to quickly view criminal activity and hold people accountable. However, in a decentralized system, that’s far more difficult. Because people operate pseudonymously, fraudulent or criminal activity is harder to trace. That means that blockchains could become a hotbed for illegal activity, including drug trafficking, or money laundering. In any case, the same can be said about the dollar. Criminals like Pablo Escobar or Osama bin Laden were happy to utilize the dollar to their advantage.

Secondly, as with any new technology, users unfamiliar with the blockchain might not trust it with their information or personal finances. Alternatively, this lack of familiarity might mean that they are susceptible to scams that prey on human errors rather than technological ones.

Finally, frequently hashing and storing large amounts of information can take computational power. This means that until someone devises a hardware or software solution, blockchains will be slow. Moreover, the energy required to maintain the blockchain so that all blocks are online in multiple copies for checking is large, which itself will mean higher costs.

Electricity Costs and Climate Change

Proof-of-Work blockchains have extremely heavy requirements when it comes to electricity. In fact, Bitcoin alone uses 150 Terawatt Hours, more electricity than Argentina, every single year. Computers will draw significant amounts of power in order to simply sustain the blockchain in the background, without even mentioning the process of extending it.

In the modern day, this poses a significant challenge because of the impacts of climate change. Currently, all of our methods of generating electricity have an impact on the climate. Even solar panels take away land from nature and can require unsustainable practices to build. As a result, the introduction of a vast new framework that requires copious amounts of electricity threatens our planet. 

That being said, many blockchains are turning away from Proof-of-Work. 2022 saw the historic Ethereum ‘Merge’, where the Ethereum blockchain switched to Proof-of-Stake after a huge collective effort by the Ethereum Foundation. The move will cut the energy consumption of Ethereum by 99.95%.

One of the potential uses of the blockchain in the future will be to reliably track the ownership of real world assets. Usually, this involves an asset holder logging the transaction in the blockchain. However, there is a weak link in this system: humans.

What if you give something to a friend and forget to log it in the blockchain? It won’t be logged in the Blockchain, so your friend won’t be the registered owner – they’ll never be able to sell or transfer ownership to anyone else. Here’s another problem: what if someone dies, and you inherit the property? Obviously, the previous owner will never be able to log the change in ownership in the Blockchain.

In order for the Blockchain to reach a state where it covers all of our needs, developers are going to have to think of innovative new solutions to the problems associated with human errors and imperfections.

Gas Fees

Another drawback of the blockchain is that transactions are not free. While traditional banks often earn money indirectly and mostly don’t charge for transactions, blockchains charge fees every time you send money. On the blockchain, transaction fees are explicit and paid to the network participants, who help check that transactions are legitimate. This is done through consensus mechanisms: getting multiple different computers, also known as nodes, to check the authenticity of another block.

In the Ethereum network, these transaction fees are called  ‘gas fees’. These are something you will need to pay each time you make a transaction on the blockchain. These fees can rake up quickly. When networks are congested fees can shoot up and it’s possible that some are upwards of $60 for each transaction.

You will forget 90% of this article in 7 days.

Download Kinnu to have fun learning, broaden your horizons, and remember what you read. Forever.

You might also like

Redefining Communities;

Can companies work without bosses?

NFTs;

So you can be a pretentious art snob in two different universes

Crypto Scandals;

Not a how-to guide

How does Decentralized Finance Work?;

The exciting prospect of you trusting your hard-earned dollars to … nobody?

Cryptocurrency;

Crypto doesn’t have to be cryptic

What is Web3?;

A fad or the next technological revolution?

Copyright (c) 2023 Kinnu Ltd.