So, what exactly is a “Blockchain” ?
“A blockchain is a cryptographically secure, decentralized ledger of all transactions across a peer-to-peer network. Using this blockchain technology, participants (or nodes) can confirm transactions into this ledger without the need for a central certifying authority.”
Wait, WTF ? “cryptographically, decentralized ledger of transactions in a p2p network”, What? ELI5!
Ok. Let’s take a step back. Picture yourself sitting in a bench in central park. It’s a beautiful day.
You have brought 3 apples with you. You want to give me one of those apples. So what do you do ?
You give me one apple. Hooray ! Simple, right ?
What exactly happened right now ? You physically took an apple and put it in my hand.
How do you know that ? You were there. You put in my hand. You touched it and made sure that I got the apple.
You didn’t really need a third person to help you make that transfer. You did not have to call your famous serial entrepreneur uncle to sit with us and confirm that you actually gave me the apple.
You had three apples, you gave me one apple. Now, you have two apples.
Now I can do what I want with that apple you gave me, I can eat that apple or I can even give it to someone else or further yet, I can give it back to you! This is what an in-person physical exchange looks like, it’s pretty much the same if you are giving me an orange, a quarter or a dollar bill. Physical exchanges are pretty easy.
So why are we talking about exchanging apples and what does this have to do with a blockchain?
Ok. Let’s just imagine that you have just one “digital apple”. And you decide to give me that digital apple. (I am happy that you want to give me that “digital apple” btw.)
Now, that’s pretty interesting !
How do I really know that that “digital apple” that used to be yours, is now mine ? Take a second and think about that. It’s getting complicted, right ?
How do I know that you din’t actually make copies of that digital apple and gave it to someone else first ? How do I know that you din’t send that digital apple to your serial entrepreneur uncle first or some other friend? Does the digital apple that you gave me actually even exist in the first place?
As you can see, digital exchanges are a bit of a problem. It isn’t the same thing as you giving me a physical apple.
There’s actually a name for this problem. It’s called the double-spending problem. You can read more about it here. You can read about it later though. For now, all you need to know that is it’s not an easy problem to solve — giving someone digital apples.
Try to think of a solution on your own. How would you solve this?
Oh Yes ! Why not keep track of the digital apples you had, and how many digital apples you gave someone ? You can literally track all these exchanges or transactions of digital apples in an accounting book or a ledger of some sort. This way you can’t really give away digital apples you don’t have, because there’s a record of it. Yay !
But wait who keeps this magical record of all transactions taking place ? Well, these are essentially digital transactions and you could probably ask your serial-entrepreneur uncle to keep this digital ledger safely in his computer.
Awesome ! You solved your problem of sending digital apples ! Yes ?
NO.
There are some pretty big problems with this approach. Do you really trust your uncle ? What if someone else got hold of this digital ledger and messed with the transactions ? What if your uncle or some hacker out there just added digital apples out of nowhere ?
With the physical apples, it was just you and me. It was so damn simple ! Now with these digital apples — you have a digital ledger that keeps hold of all the transactions and your uncle keeps the ledger in his computer (which btw, could actually get hacked or manipulated). You introduced a third person (your uncle) to exchange a digital apple and introduced so many new problems.
Is there a way to make it simple again, you know like the exchange of physical apples? Just you and me ! It seems kind of tough because the apples are digital.
So what exactly is the solution ? How can I send and receive digital apples to multiple people without having your serial entrepreneur uncle safely holding record of all the transactions (ledger) ?
The solution is actually pretty elegant. Why don’t you give the ledger — to everybody involved? Instead of having your uncle keep the digital ledger on his computer, it will live in everyone’s computers. All the transactions that have ever happened will be recorded in this digital ledger and everyone will have copy.
Now since your uncle isn’t the only one with the digital ledger (or isn’t a central authority) and everyone has it, its pretty difficult for someone to cheat or manipulate. Wait, why can’t someone just change his or her digital ledger and cheat ? Well, because then it wouldn’t really sync up with everybody is the system. It’s a pretty tough system to beat. Whenever a change is made to the digital ledger, everyone in the network has to agree that it’s valid and will have to update their copies.
So now the ledger is not just controlled by one person, so you know that no one can just simply decide to give someone more digital apples if he doesn’t have it.
So what does everyone get for validating that the transaction is true and that every digital ledger copy is up to date ? Well, more digital apples for you as a reward, of course. This is the distributed consensus mechanism & mining bitcoin employs. Let’s not get carried away. More on this on a later post.
So what have I just described ? What is this distributed digital ledger where everyone has a copy of and verifies the transactions in it ? Yep, it’s what a blockchain is.
So do you see what actually happened ? What does this public distributed ledger of transactions actually enable ? For one, I could now exchange “digital apples” safely and securely without a third party (your uncle) with multiple parties or friends.
So back to our definition of a blockchain.
“A blockchain is a cryptographically secure, decentralized ledger (or shared database) of all transactions across a peer-to-peer network. Using this blockchain technology, participants (or nodes) can confirm transactions into this ledger without the need for a central certifying authority.”
Ok, you get everything except the whole “cryptographically secure” part? Hang on to that, I will shed some light on it in an upcoming series.
Here’s another definition of what a blockchain is.
“The blockchain is an incorruptible digital ledger of economic transactions that can be programmed to record not just financial transactions but virtually everything of value”. -Don & Alex Tapscott, authors of Blockchain Revolution (2016).
Here’s another interesting analogy I came across on BlockGeeks.com
Think of the blockchain as a distributed database.
Picture a spreadsheet that is duplicated thousands of times across a network of computers. Then imagine that this network is designed to regularly update this spreadsheet and you have a basic understanding of the blockchain.
Information held on a blockchain exists as a shared — and continually reconciled — database. This is a way of using the network that has obvious benefits. The blockchain database isn’t stored in any single location, meaning the records it keeps are truly public and easily verifiable. No centralized version of this information exists for a hacker to corrupt. Hosted by millions of computers simultaneously, its data is accessible to anyone on the internet.
To go in deeper with the Google spreadsheet analogy, I would like you to read this piece from a blockchain specialist.
Blockchain as Google Docs
“The traditional way of sharing documents with collaboration is to send a Microsoft Word document to another recipient, and ask them to make revisions to it. The problem with that scenario is that you need to wait until receiving a return copy before you can see or make other changes because you are locked out of editing it until the other person is done with it. That’s how databases work today. Two owners can’t be messing with the same record at once.That’s how banks maintain money balances and transfers; they briefly lock access (or decrease the balance) while they make a transfer, then update the other side, then re-open access (or update again).With Google Docs (or Google Sheets), both parties have access to the same document at the same time, and the single version of that document is always visible to both of them. It is like a shared ledger, but it is a shared document. The distributed part comes into play when sharing involves a number of people.
Imagine the number of legal documents that should be used that way. Instead of passing them to each other, losing track of versions, and not being in sync with the other version, why can’t *all* business documents become shared instead of transferred back and forth? So many types of legal contracts would be ideal for that kind of workflow.You don’t need a blockchain to share documents, but the shared documents analogy is a powerful one.” -William Mougayar, Venture advisor, 4x entrepreneur, marketer, strategist, and blockchain specialist.
So, what is a blockchain?
A blockchain in simplest terms is shared database. This database is called a ledger. So just like a bank, the ledgers of simple blockchains keep track of currency(in this case, cryptocurrency) ownership. It essentially keeps tracks, accounts, the amounts they hold and transfer records. But unlike a centralized bank, everyone in the system has a copy of the ledger and can verify each other’s account. This is the decentralized (or distributed) part of the blockchain.
I know what you are thinking. I seem to have those mystical powers. So why use a blockchain ? Why not just have a centralized database ? Why a shared database ? Why a distributed ledger ? This makes no sense at all. Right ?
Wrong.
To really understand blockchains, we need to first understand databases and networks and how they relate to each other.
Let’s go back in time, back to the early 1960s.
The First Act (Databases)
The actual history of the blockchain story actually starts in the early 1960s when the database as we currently know it was created. If you are imagining a big white room with several racks of spinning tape drives neatly arranged next to each other, you are on the right corner of history. This was the natural way data was stored, in central physical locations. This is the centralized approach, meaning the location and accessing of data was controlled by some central authority. Big organizations paid big money to the likes of IBM, Oracle etc. (the central authority) to store their precious data (customer data, trading data etc.) in these centralized databases.
Centralized systems can be manipulated, so all these organizations had to trust the owners of these systems to keep their data secure and preserve its integrity. You may not think of this world of databases, but we essentially live in it. Centralized databases are still the most common today, powering most of our online and offline applications and transactions. Every time you use Facebook to stalk someone or get on Amazon to buy your toilet paper or watch a movie on Netflix, there’s a database or a mess of them lurking underneath the surface. You are constantly interacting with them. We live through these databases and they are as pervasive as oxygen. They are the bloodline of our generation.
The Second Act (World Wide Web)
The second act of the incredible blockchain story is the arrival of the World Wide Web. Researchers started playing around with protocols like telnet, gopher, usenet, http, email etc. to interact with different nodes in a network. Sometime around the 1980s, we started really getting serious about computer networking and with the arrival of Tim Berners-Lee, the adoption of the web and the internet skyrocketed. To this day, we are still riding this technological wave and a wide array of new services are emerging, think Airbnb, Uber, Spotify etc., disrupting industries along the way.
So what exactly does the internet and the web have to do with databases, the first act ? Let’s clarify that. Think about a simple blog. It’s one of the most common uses of a centralized database. The user writes a blog and hits the publish button. What actually happens in the background ? The server receives this request, inserts the data(the blog)into some database and serves it up for other people to read. Simple right ? Well, not exactly. Take note of a couple of things here.
First, the user has to trust that the server does what it’s supposed to do. A hacker could technically infilterate the server and commit malicious acts. Second, if there’s no database backup, determining what’s changed and reversing the damage might be impossible. Hold that thought for a second. I promise I will come back to it.
Eventually, we had a large number of organizations storing their data in these big white rooms and also had a network of programs or applications interacting with this data constantly. Furthermore, as organizations built more services, the need arose to share large amounts of data amongst themselves. Human beings are smart and the brainy computer scientists eventually came up with several ways to ease the burden of sharing large amounts of data by distributing data across parties needing to share. Yet, the reading and/or writing data was controlled by one or more parties and were pretty much subject to similar corruptions as centralized databases (just like our simple blog example).
Here’s the problem, the databases and the networks never really learned to get along. In the real world the technical costs of connecting databases across organisations are huge. Again, as resourceful as we are, the brainy computer scientists came up with some ingenious ways to have share data amongst different organisations.
Take for example two commerical organisations that wanted to share their data, one approach would be to directly connect the different machines together and work out the quirks as you go. Organisations would try to automate their back end connections and all the issues that arose would have to be hashed out by hand. These issues could range from the instability of the peer connections to the unpredictabilty of software changes on one side. It’s difficult, expensive and error prone. Of course, several attempts have been made to clarify this mess and streamline interoperability by introducing standards like JSON,SOAP,WSDL etc. to help you in your integration processes. Needless to say, the reason there are so many standards is because none of them work properly.
Another approach to solve this problem of sharing data or interoperability is to basically cut through the complexity of writing software to directly connect peers and put somebody in charge. Think of VISA for instance, all peers would agree to connect to VISA via their standard interface. So exactly is the problem with this approach? Well, it’s a monopoly. This essentially leads to problem of platform economics. If you start relying on an intermediary who charges whatver they like then it eventually turns up being a huge cost to all the organizations involved. We don’t really need that.
One important fact to note in the above models is the concept of trust amongst organizations that are trying to share data. In both, the diverse peers model and the hub and spoke model, its required all the participants trust each other. We had to trust that the central authority (VISA, for instance) wouldn’t do anything malicious or we had to trust that all the organizations agreed on a particular state of the data.
The Third Act (Blockchains)
So what about some kind of protocol? Why can’t we all agree on how to do things, how to connect to peers, share data without a central authority, gain trust etc. and just go on and do them, instead of arguing about interoperability standards etc.? Well, the truth is that its inherently complex to define a protocol and have everyone agree on a particular protocol to share data. This brings us to our third act. The blockchain.
A blockchain at it’s heart is both a protocol and a shared database. Blockchains eliminate the problem of sharing data and trust through some really interesting math and techniques.
A blockchain is fully decentralized — reading/writing to the database is completely decentralized and secure. No single person or group controls the blockchain. It’s extremely fault tolerant. While fault tolerance is not unique to blockchains alone, it takes the concept to its logical extreme by having every participant sharing the database validate its changes. Moreover, transactions into he blockchain can be verified by anyone, without a third party. Underline without a third party. It also has mechanisms built in that make it hard to tamper with historical records, or at least make it easy to detect when someone is trying to do so.
All of this may sound a bit confusing when you are hearing it for the first time.
So, let’s remind ourselves again why we would want to use a blockchain ?
Blockchains are used when multiple parties, perhaps located across the world, need to share data and transfer value without trusting each other. It’s that simple.
The financial world describes this trust as the counter party risk, i.e. what’s the risk that the other party won’t hold up their end of the bargain? Blockchains completely remove the counter party risk through a revolutionary system of mathematics, cryptography and peer-to-peer networking.
This is just a gentle non technical introduction to blockchains. I will post more on the technicals underpinnings soon.