blockchain

If ‘bitcoin’ came into your mind seeing the word- ‘blockchain’, you are not alone. Let me tell you, blockchain is a tech and bitcoin is one of its application areas.

So, what exactly is blockchain?

Simply put, it is a technology to store data. Further, it is a technology to store data with no central authority to control it, distributed over a peer-to-peer network of computers with everyone in the network to access the data.

As its name suggests, the data is stored, structured in blocks, and they are linked with each other in a chain.

a block in  blockchain
a block

Hash?

Hash is the unique identification of a block. Something like a fingerprint associated with the particular block or the encryption of that block.

As we can see, a block contains–data associated with it, the hash (unique identification of it), and the hash of the previous block. This is how data is structured in a block and the chain of the blocks leads to the database- blockchain.

How decentralization is implied in blockchain.

Consider a scenario: You own a bank and you have a database containing account details of every account holder of your bank. What if you run away with that database? Consider more practical scenario: you have database stored in computers associated with XYZ data center. What if data center burns or gets damaged? The information is lost. And here comes the blockchain.

Since it is a decentralized network of computers, the data is shared with every computer in a network. Those computers are called nodes.

If every node has access to the data, why can’t a single node change or tamper data?

structure of blocks in blockchain
structure of blockchain

Okay. Let’s consider you wish to change the data. When you do that, the hash associated with the data changes. If hash of a block changes, the previous hash of upcoming hash also changes and the process continues since the blocks are linked with each other. Hence, the data is about impossible to tamper.

How does data get added in blockchain? OR, how a new block is added?

In the database of your bank based on blockchain, consider, you want to add a record of new account holder. With data and hash, you add block in the network and now it is to be verified by particular computers in the network which are called miners. Once the correct procedure of adding data (without disrupting the previous block) is followed and over 50% consensus of computers in a network verify it, the data is added in blockchain. Moreover, the record can be viewed by everyone in the network and everyone can verify it by utilizing the public ledger.

Finally, let’s be clear on how a transaction can be carried in blockchain:

I want you to send $20. You and I are in a blockchain network with 50000 other nodes. Now, a new block will be created with a public key of mine and yours with the details of the transaction. Other nodes in the same network will record the action that I want to send $20 to you. Suppose a guy in the network wants that money to be sent to him instead of you. But, the other computers will not verify it since it is not intended. Finally, the transaction is carried out.

Leave a Reply

Your email address will not be published. Required fields are marked *