Understanding Blockchain — Part I

Akarsh Agarwal
MLG Blockchain
Published in
5 min readOct 6, 2017

The world of technology provides us with the “Internet”. This may sound so simple, but the Internet encompasses a lot more than I or you could ever imagine. It has brought mass information and knowledge to a mere click away. And over the years, it has drastically reduced the pain of searching answers to our questions.

Information found on the Web is nothing but data hosted somewhere in the world and we access it using either IP Addresses or Domain Names (URLs). This data is of varied forms, public or private, document or video; anything which is binary (1s and 0s) is considered to be a part of data. Such massive amounts of data needs to be protected from malicious and catastrophic usage.

Until the last decade, most of the data was hosted on data-centers situated in geographically different locations to prevent outage of access to data, in the event that a region’s data-center goes down. The data was stored and protected to prevent others from sneaking into the system and causing harm. These days, it has become harder to protect due to hackers getting better day by day and learning new techniques to break into the security systems.

Banks and financial institutions are the ones that are most affected by this type of intrusion. What if, all you had was stolen in a matter of seconds just because there was security breach in data-centers. You could lose all your life’s earnings in a heartbeat. Ensuring the financial security and protection of stakeholders has become a major concern for bans across the world.

So, what do we do now?

Once upon a time, a new idea came up in the mind of the mysterious Satoshi Nakamoto. An idea so diverse and fail-safe that it has increased its credibility over the past 8 years. It was the “Bitcoin”, the digital currency of the digital era. What I aim to focus on is not the currency but the technology and architecture it uses to store it’s transactions, the blockchain technology.

Blockchain; in layman’s language chain of blocks; in an accountant’s language, a distributed ledger; and in a techie’s language, peer-to-peer Database; has brought the decentralization concept to life. This removes the major component of a database, being hosted on a central server, to a distributed environment. Once where peers connected to the network host themselves data, track and monitor all changes made to the database via P2P protocols.

Finance runs on statistics. And statistically, there is a much lower probability of all peers going down simultaneously, when situated across the globe. This ensures that the network is up and running all the time.

But this doesn’t sound anything different from what we already have, does it? Then why do we keep talking about how the blockchain will change everything? How is it unique? We shall answer all these questions in the paragraphs to come, to make you understand what are the blockchain’s real capabilities.

Blockchain, a distributed ledger, is a chain of blocks, where each block contains some sort of data, encrypted by the user creating the block, by their own set of keys (public and private). Each block, when constructed and added to the chain, is broad-casted, by the creator of the block, to other peers about the change in the height of the chain. Now, as the data is not hosted on a central server, every peer has its own copy of the chain and updates it when it receives a broadcast message. This ensures that even if one copy of the chain gets corrupted, we have other copies to replace the corrupted one and ensure the availability. Also, it makes sure that whenever other peers add to the chain, they add on top of the updated chain and not the old copy that they have.

Each block when constructed is hashed to get a hash value, that represents the block. This hash value is shared with every peer connected to the network. Also, a user who has the hash value to the previous block can only attach a new block to the chain, because the hash value of previous block, is an integral part of the data of the next block.

This ensures that when someone has tampered with the data in the previous block, the hashed value in the next block will defer and we come to know that there is some integrity issues with this copy of the chain. So, apart from acting as a link between blocks, the hash values act as a verifying entity of the block.

For a hacker to completely modify the data, he/she has to change the data of the block in every corresponding block up to the last block up the chain, and make sure that every peer receives the new hash value. This may sound simple, but is computationally expensive and requires that every peer’s copy should be changed at a single point of time to ensure that the change has been made. For example, we have 1 million peers connected to the network, so to make sure everyone has the edited copy made by the hacker, he/she has to change the 1 million copies of the network simultaneously in one go, which is not only computationally expensive but highly impossible to do, considering the network of infrastructure across different countries.

Also, hashing the block with keys, make it tamper proof as to read the data correctly and able to edit it, anyone would need those keys, which has to be protected by the peer. Even if the hacker has access to the keys, there is this computationally expensive problem to face, which just adds to the difficulty in tampering with the chain.

What’s more, current databases support edit facility and once edited, the old data is lost or logged into a separate file, which may be or may not be easy to edit to reflect that change. But in blockchain, once added, nothing gets edited. It is type of “Append Only Database”, where peers keep on adding to the chain. This makes sure that old values for the data still exists on the chain, provides an easier way to track the history compared to logs that other databases generate.

The above description gives proof about how immutability is supported by blockchain to avoid any tampering with the data. This makes sure that everyone works on a legit copy and add to the correct chain’s copy.

Every blockchain should have a sufficient number of peers to make sure that this holds out. You don’t provide security to blockchain by adding complex algorithms, but rather by adding more peers which would collectively make sure that it is not tampered and edited for their own interests.

--

--

Akarsh Agarwal
MLG Blockchain

All about Distributed Systems and Stakeholder Management. #golang #distributedsystems #management