Blockchain Unblocked— Part 1: The Basics

Deepika Karanji
7 min readFeb 2, 2022

--

In this article, we will discuss:

- What is blockchain? How is it similar yet different to banks?

- What are ledgers, blocks, chains, networks, nodes/peers?

- Types of networks

- 51% attack

When you want to sell something, you find a buyer — directly or indirectly, and give them your product, in exchange for something (usually money). This exchange is called a Transaction.

The money that you receive, is usually government regulated currency — like Rupees or Dollars. Governments, along with Central banks like The Reserve Bank of India, control the flow of money and its circulation in the country.

In other words,

Through a series of intermediaries, such as banks and financial institutions, governments distribute and regulate the flow and use of money in an economy. Thus, they can dictate how it is transferred, sectors where it is distributed, and trace its utility. They also earn revenue from it by taxing earnings of individuals and corporations. — Investopedia

The only reason you and I care about our money and bank accounts, is because we know it has value. We know that the value of the numbers in our bank account allows us to buy what we want, and that this value will not just vanish. We trust our banks and governments to keep up the value of our money.

On salary day, we see that the numbers in our bank account have increased and we smile smugly, because we know that this increase in numbers means we have the power to exchange a few of those numbers for our favourite (but overrated) Starbucks coffee. And we know that Starbucks can most definitely get our name wrong, but they most definitely cannot refuse to accept these numbers in exchange for coffee — i.e, we are confident about the value our money has. This confidence is driven by the fact that our government maintains its value through sensible regulation.

Now all of the above might seem like a cool story, but why am I telling you this?

I will answer that shortly.

Now, imagine a world where we don’t need banks. We don’t need governments to regulate money. We just — create money out of thin air! We become magicians! The value of the money we create is no longer government regulated, but people regulated! That is, you and I decide the value of the money! To send some money, I no longer need a bank to perform that action for me! I can just do it without any intermediary! WILD right?

News flash: We actually live in that world right now! There exists a technology called “Blockchain” that allows us to do these transactions without any middlemen/women in the way!

But you may say, Hey Deepika, you literally just established in the first paragraph that trust is an important part of a transaction — we need to trust the buyer/seller, and also need to trust the value of what we give/receive. If there are no banks which can take responsibility for a transaction, then how will I ever know whether the transaction really happened correctly or not? Now tomorrow, if my bank balance is showing some wrong numbers, I can pull up the bank statements (which show my transactions) and go through each record, call up the bank and get them to rectify whatever backend error happened. I trust my bank because I trust my government.

But now if people are just creating things and just sending it to each other with ABSOLUTELY NO regulation, who will be keeping a check of these transaction statements? Anyone can modify these statements right? Someone can just change a record that originally says “Deepika paid Uma $100” to “Deepika owes Uma $100000”. Then will you, Deepika, really owe Uma $100000??

Excellent questions! Let us break it down, and start with some basic concepts:

  1. Where are transactions (with no banks/intermediaries) stored in Blockchain?

In Blockchain, all transactions are maintained on something called a “Block”. Block: A container data structure that stores information about transactions. It is like your bank account statement — except that this transaction detail is not yet necessarily valid yet.

A chain of blocks which contain valid transactions forms a Blockchain!

2. In our bank scenario, our bank statement is stored in the bank’s database. Where are these blocks stored?

In the bank scenario, there is one central bank which has a database stored on some computers. These computers are owned by the bank. (Engineers: yes, I am talking about managed DBs and other cloud services as well). The bank’s computers communicate with each other through their own internal network.

In Blockchain, the blocks are also stored on a database, but the database, known as Ledger, is not managed by any particular body. Instead, all the computers(aka Nodes/ Peers) on the blockchain network get a copy of this Ledger. This is what is termed as “Distributed Ledger”. Old blocks can never be deleted from the ledger. Only new blocks can be added irreversibly.

3. Who owns these Nodes in the blockchain?

You and I own them! If you own a computer which satisfies some minimum hardware requirements, you can sort of sign it up to be a part of a Blockchain network, and your computer will receive a copy of the ledger.

4. But if my node has a copy of the ledger, can’t I modify some transaction on some block in the ledger and make Deepika owe Uma $10000?

Haha you can attempt to do so, but remember? Every single node on the network has a copy of the ledger. So if you tamper with some record, there will be 100’s of other nodes which will have the original ledger! So the Blockchain algorithm uses the concept of democracy and discards your version of the ledger and retains the version that exists in majority.

It might also be a bit soon to mention, but the reason it becomes really difficult to tamper with any block in a blockchain is because if you change any one block, the technology is built such that you will have to modify every block linked after the tampered block, in order to make it a valid chain( I will go into how and why in Part 2). This is very difficult to do, and even if you do pull it off, the decentralised distributed ledger system will quickly enforce democracy. That is why addition of a new block is said to be “irreversible” or “tamper proof”.

However, there is something called the 51% attack. To give a quick brief, 51% attack is what happens when one evil person or a bunch of evil people get control of the majority of the blockchain network. So if there are 100 nodes on the network, the evil team owns 51 of those nodes. They then have the power to tamper with the ledger, and since they are the majority, the tampered ledger becomes the truth. But there are many nuances to this attack, more of which we shall discuss later.

5. How many Blockchain networks are there? Can I make my own network? On which network do I sort of register my computer?

There at least 100 blockchain networks today. Darren Nelsen gives a pretty good explanation here . In simple words, you may have heard of Bitcoin, Ethereum, Ravencoin, etc. Each of these can be thought of as Blockchain projects, and each project has its own Blockchain.

And each project has its own pros and cons, so depending on which project you are interested in, you can decide to sign up your computer to become a peer in that project’s network. I am definitely glossing over this, but only because I intend to give the complete beginner a good understanding of how this technology works, without scaring them away!

Blockchain networks are of 4 types: Public, Private, Hybrid, Consortium.

Credits: Foley.com

Usually when people talk about “mining”, they have some nodes(aka their computers) running on a public blockchain network, and they are “mining” coins/tokens like Bitcoin or Ethereum.

There are also private chains that don’t have a coin or token, but track information for particular business purposes. These are often built on Hyperledger or Corda, where the chain is only accessible to ‘permissioned’ users, i.e specific people within the organisation.

I will pause at this point to list a few more questions that may have popped up in your mind:

  1. How does the first block in a blockchain get created?
  2. How do I log my transaction inside a block?
  3. What is mining? How does it work? And how do people earn from it?
  4. I mention private chains being used to particular business purposes — Are there other use cases to Blockchain than just tracking monetary transactions?
  5. What are coins/ tokens and who creates them?
  6. What is a valid transaction?

Worry not, I assure you, all these questions will be answered as we go through each article in this series!

If you have any suggestions/ comments, do feel free to drop them below. You can always email me at deeps.karanji2@gmail.com. If you learnt something from this article, do consider showing your appreciation through some claps! :”) I will keep updating the series with new articles every week! P.S: I am learning as I write, so all corrections are welcome!

Instagram: @dpk_99

--

--

Deepika Karanji

Exploring new technologies, when I am not cooking, trekking or playing with dogs!