What on earth is Blockchain?
Ashi Dhanatunge
Head of Strategic BU & Head of Partnerships at Acentura || Building networks and partnerships Globally || Digital Transformation Evangelist || SAP, Microsoft, RedHat, Relex Solutions, AWS, Centric, UiPath ||????♂? ??
So, there are these technological buzzwords that accost us day in and day out, whether it is at work, in the news, on social media or even having a chat with a friend. Most of the time we haven’t the foggiest idea as to what it actually means or what it actually does. But we nod along and go with it and use those buzzwords anyway… am I right?
Unless you’ve been in hibernation for the last few years, I am sure you’d have heard the terms Bitcoins and Blockchain. Even the who’ve never mined a cryptocurrency or understand how it works let alone know what it means are talking about it. It’s hard not to -these terms are talked just about everywhere. According to Gartner (world’s leading research and advisory company) Blockchain is one of the top three most hyped technologies of 2019 along with Artificial Intelligence and Intelligent Things.
Coming from a non-technical background, (even though I have found my passion in making digital solutions simple with Vevro) I have more non-technical friends than technical ones. This means I get asked about all of these buzzwords all the time (especially since Vevro has become one of the leading Artificial Intelligence and Cognitive Services providers in the region and having been endorsed by Microsoft as their solutions partner). I guess it’s the same with a lot of the others out there too. So, I have decided to write in plain old English for anyone to read and understand what Blockchain is.
Do we even need Blockchain? I mean it’s so complex!
Technology simply exists to make our lives simple and efficient. So instead of defining Blockchain, let’s start off with the problem it solves.
Imagine, you have a sister. she is studying overseas. During one of your routine calls Kayla mentions that her laptop is broken and is in need of buying a new one. “Please can you buy me a new laptop?” she says. You reply, “sure thing, I’ll transfer you some money”.
You then go to your bank (let’s keep online banking out of this just to make it simple) and ask the bank to transfer $1,000 from my account to Kayla’s account.
The bank teller says “Yes, sir”. He/she checks your account balance to see if you have enough balance to make the transfer. Because you’re a rich man, you have more than enough. Therefore, the teller makes an entry in the registry.
You call Kayla and tell her the money has been transferred. “You can withdraw the $1,000 the next time you go to the bank”.
Basically, you both just trusted the bank to manage and handle your money. There was no physical moving of dollar bills to transfer the money. It was just an entry in the register. More precisely, it was an entry in a register that neither you nor Kayla had any control or owns.
And there poses the problem of the current systems.
For years we have depended on and trusted these middlemen within middlemen. And a valid question at this point would be “what is wrong with trusting these middlemen?”. The problem is that they are singular in number – it only requires one person or one establishment to become corrupt – either intentionally or unintentionally.
- What if that register gets destroyed by natural disasters or by accident? (i.e. fire, water, wind etc).
- What if by mistake the bank teller had entered the wrong number? (an extra zero perhaps).
- What if he/she did that on purpose?
All this time we have been putting all of our eggs into one basket. And that is not even our basket – we just think it’s ours.
Could there be a way where we can transfer money without the bank?
I think we’ll need to ask a better question to really answer this question. If we really look at it, (and as mentioned earlier) transferring money is basically just an entry in a register.
So, our better question would then be… Is there a way to maintain the register ourselves?
The answer is what you might have already guessed. Yes, it is Blockchain. It is a method which allows us to maintain the register among ourselves instead of depending on another to do it for us.
Let’s check out how this distributed register works – remember, we are in charge of the register – yes, all of us!
So how does it work?
The only requirement of this method is to have enough likeminded people who don’t want to depend on another party. Only then can this group be able to maintain the register themselves.
How many are enough? At least three are needed. Let’s take 10 people as our example group. By mutual agreement, each of the members of this party have each other’s account details at all times – without knowing their identities.
1. An empty folder
Everyone will have an empty folder with only their info to start with. As we progress, all ten in the group will keep adding pages to their individual and currently empty folders. This collection of pages will form the register that tracks the transactions.
*Note: Initially, when the folders are empty – obviously there’s no money in them. It is at this point that the introductory reward associated with cryptocurrency (let’s take Bitcoin as the example) gets introduced to the system.
2. When a transaction happens
Everyone in the system has a blank page in front of them. Everyone is ready to write down any transactions within their group – they are ready to be the masters of their own eggs.
Now, #9 wants to send $15 to #3 – so, #9 shouts and tells everyone “I want to transfer $15 to #3. Make a note of it please”.
Everyone checks whether #9 has enough balance to transfer to #3 and if the balance is sufficient everyone makes a note of it on their up to now blank pages.
The transaction is now done.
1. Transactions keep happening
Whenever the group needs to make a transaction, they shout it out to the rest of the group. As soon as a person hears the shout out, they list it on his/her page. This keeps on going until everyone runs out of space on their page. It’s now time to store away the filled page in the folder and start on a fresh page and repeat the process above.
2. Putting away the page
We now need to keep the filled-up page secure. The group seals it with a unique key which is agreed upon by everyone in the group. By sealing, the group makes sure no one can make any changes once its put away in the folders – not today, tomorrow or even after a year. It will stay sealed in the folder. If everyone trusts the seal, then everyone trusts the content of the page. This then is the crux of the method.
Tech Geek Time: Sealing is the process which in cryptocurrency is called mining – but for simplicity let’s call it sealing.
Traditionally, the third party/middlemen (banks) provided the trust (most of the time) that there won’t be any alterations to their registry entry. In this new distributed and de-centralised system however, the seal will provide the trust instead.
How is the page sealed?
Before getting into this, let’s find out how the seal works. Let’s call this system the magic machine (like a machine that makes ice cream – you add all the ingredients from one side and ice cream (something different) appears from the other).
The magic machine
Imagine a machine surrounded by thick walls – into which, you send a box containing one thing from the left and a box containing something else comes out of the right.
Tech Geek Time: This is called the “Hash Function”, but since we are keeping it simple let’s go with the magic machine.
Let’s say the number 4 is sent in from the left side, the completely random word “dcbea” is thrown out from the right side. No one knows how the number 4 was converted into this word and it is an irreversible process. Given the output from the right “dcbea” it is impossible to find what was fed in from the left. That being said, each and every time the number 4 is being fed in the word “dcbea” will be the output.
Let’s try sending in a different number. How about 26?
Well that gave not just letters but numbers also – so the words contain numbers too.
What if you get asked to find the input of a words starting from 000’s – Can you do it? So, there is only one obvious way to find out the input from the output and that is to try every number in the universe one by one until a word starting with 000s are found. Being optimistic, it’ll probably take a few thousand numbers to find the number on the left.
It would be painstakingly difficult and neigh on impossible to calculate the input given the output. But at the same time, it will always be incredibly easy to verify if the predicted input yields the required output. Remember that the machine spits out the same word for a number every time.
So, the most important property of such a machine is that – given an output it is extremely difficult bordering on impossible to calculate the input, but given the input and the output, it is pretty easy to verify whether the input leads to the output.
Okay, now do keep this magic machine (Hashing Function) in mind throughout the rest of the post.
How does the magic machine help seal the pages?
As we have done so up to now, let’s start with an imaginary situation.
You are given two boxes - the first box contains the number 20893. You are then asked to figure out a number that when added to the number in the first box and fed to the machine will give a word that starts with three leading zeroes.
Similar to that of the previous occasion, the only way to calculate such a number is by trying every number available in the entire universe. After several thousand attempts, you might stumble upon a number, say 21191, which, when added to 20893 (i.e. 21191 + 20893 = 42084) and fed to the magic machine, that will provide a word that satisfies your requirement.
In such a case, this number, 21191 becomes the seal for the number 20893. Assume there is a page that bears the number 20893 written on it. To seal that page (i.e. no one can change the contents of it), we will put a badge labeled ‘21191’ on top of it. As soon as the sealing number (i.e. 21191) is stuck on the page, the page is sealed.
Tech Geek Time: This sealing number is known as the “Proof of Work” – it is to prove that efforts have been made to calculate it. Let’s keep calling it the “sealing number” for now.
If verification is required as to whether the page was sealed, all that is needed to be done is to add the contents of the page with the sealing number and feed to the machine. In this hypothetical scenario, the response comes back with 000’s as the beginning of the word, the contents were untouched. If the word that comes out doesn’t meet the requirement of 000, the page has been compromised and is of no use. A similar mechanism will be used to seal all of the pages.
Last but not least… sealing the page
In order to seal the page that contains the transactions the group has made, a number must be figured out which, when added to the list of transactions and fed to the magic machine, a word starting with the 000’s is given out from the right.
* Note: The phrase I’ve been using “word starting with the 000’s is only an example to illustrate how the Hashing Function works. In reality it is much more challenging than this.
Once that number has been calculated (it takes a lot of time and electricity, by the way) the page is sealed with that number. This sealing number will allow anyone to check the integrity of the page, in the event someone tries to change the content.
Now that we know about sealing the page, let’s get back to what happens when that tenth transaction happened and there was no more space on the page.
As soon as everyone in the group runs out of space to write on the page, they get calculating the sealing number for the page so that it can be tucked away in the folder (remember the one that was created right at the start). Everyone in the group does the calculation and the first on who figures out the sealing number announces it to the whole group.
As soon as the sealing number has been heard, everyone verifies whether it yields the required output or not. If it does, everyone marks the page with the sealing number and puts it away in their folders.
But, if for one of the group, say #5, doesn’t yield the sealing number announced – what then? Such cases are not unusual and the possible reasons are:
- Might have misheard the transactions when they were announced.
- Must have not written down the transaction correctly when announced on the group.
- Might have tried to cheat or be dishonest when writing down the transaction to favour himself or someone else in the network.
No matter the reason, #5 only has one choice and that is to discard the page and copy it from someone else from the group so he too can add it to his folder. If he doesn’t add his page to the folder, he is unable to continue writing any further transactions and therefore, he can no longer be part of the group.
Coming back, there is a good reason as to why everyone in the group calculates the number and not just wait for it to be announced by another in the group – this is where incentives come into play. The first in the group to calculate the sealing number gets rewards with free money for his/her efforts (i.e. electricity used and CPU power expended).
Indulging our imagination once more, say #3 is the first to calculate the sealing number, he gets rewarded with some free money – let’s say $5, that gets minted out of thin air (abracadabra – it appears). In other words, the account balance of #3 gets incremented with $5 without decreasing anyone else’s account balance.
This is how Bitcoin came into existence. It was the first currency to be transacted on a Blockchain (the distributed registers system we talked about at the beginning). And in return for the people to keep their efforts going, they were awarded Bitcoins.
When enough people have Bitcoins, the value grows, making more people wanting Bitcoins; which in return makes Bitcoins grow in value even further; and that makes even more people wanting Bitcoins; where the value grows even further; and so on.
And once everyone tucks away the page in their folders, they bring out a new blank page and repeat the whole process all over again — doing it for as long as they want to be part of that network.
Tech Geek Time: Here’s the punchline – think of the page as a Block of transactions and the folder where all the pages (the Blocks) are stored and inter connected as the Chain of pages (Chain), thus making it a Blockchain. Ta da!
And that is the gist of Blockchain. But is that all there is?
Okay… I deliberately left out a part to avoid confusion. But now you are ready…
Imagine, your folder already contains 5 pages that are sealed – they’re all sealed with a sealing number. But what if someone decides to go back and modify the second page in order to favour themselves? The sealing number will allow the others to detect the inconsistency of the transaction(s) right? But what if you calculate a new sealing number that fits with the modifications too and label the page with that?
So, this is what I held back – there is a little twist as to how the sealing number is calculated – precisely to stop this scenario from happening.
Protection against the modification of the sealing number
Remember how I mentioned there are two boxes? One which contains a number already and the other which the group needs to calculate? In reality, there are actually three boxes – not two. Two of these boxes contains prefilled numbers it is the third that needs calculating.
When the contents of the three boxes are added and then fed to the machine from the left, the answer that comes from the right must satisfy the required conditions.
We already know which numbers two of the boxes contain – one has the list of transactions, the other contains the sealing number. So, what’s in the third? This is the failsafe – it contains the output of the magic machine for the previous page.
This neat little trick means Blockchain makes sure that every page depends on the previous page. What this means is, if someone in the group decides to change one page, they have to modify not just the sealing numbers of all the other pages but also the content of all the other pages in order to keep the chain constant. This makes it neigh on impossible to do – we already know how difficult it is to calculate the sealing numbers – which means one dishonest person can’t beat the other nine we imagined in the scenario.
What would happen in reality is the person who is trying to cheat by amending one page, he/she will be creating another separate chain in the network. But due to the processing power it requires and the work that goes into calculating sealing numbers, that new dishonest chain can never catch up with the speed of the honest chain (one is much slower and less efficient than nine). This guarantees the honest chain as the longest chain in the network.
But wait… did the above ring any bells? One can’t beat nine… but what if… instead of one person, say six turns dishonest?
If this happens, the protocol will fall flat on its face. The so called “51% attack” (usually experienced in boardrooms). If majority of the group are dishonest and decides to cheat the rest of the group, then the protocol will fail its purpose (there is no such thing as the perfect solution, right?).
This is the only vulnerability of Blockchain and if it ever fails it will be because of this. That being said… we must give credit to the human race. History shows us that honesty and virtue trumps dishonesty and corruption. Blockchain is built on the assumption that the majority of a crowd is always honest.
And that is all there is to know about Blockchain (on its own).
The example used above is about how Blockchain can be used to control your own money (deregulation of currency) – however, Blockchain can be and will be used in other industries for various data accumulations in the future. The true capabilities of Blockchains are yet to be determined especially with the integration of other digital trends such as Artificial Intelligence and Internet of Things.
Interested in Digitalisation and looking for cutting edge digital solutions? Get in touch with us through www.vevro.com or drop us an email [email protected].