


Blockchain is a chain of blocks that contain information. Each block contains 3 elements, viz, transaction data, a hash of the block and a hash of the previous block [5]. A data can be any raw data that is stored inside the block, it can be details of a transaction stating the sender, the receiver and the amount transferred, it can also be any medical records of patient along with patient’s name and basic information in it, etc. Every blockchain has a hash, hash is a cryptographic code. We can say that a hash is a fingerprint for a block, which means every block has a unique hash. If the data of the block has been changed it will cause in a change in the hash of the block. Thus making it more secure to know that if any block has been manipulated. A block also has a hash of its previous block, which makes it a chain of blocks as every block will show the connection to a previous block and making it a chain of blocks. If the data of any block is manipulated the hash of that particular block changes resulting in disruption in chain as the next block will not be linked to any block, because it holds the hash of the unchanged block.
The first block will always have the previous hash value as zero because it is not linked to any previous block and it is also called as the genesis block. These interconnected blocks supports the decentralization of systems and ensures that the data is securely distributed and publicly visible. People also say that blockchain is a public distributed ledger.
Blockchain uses a P2P network, Peer to Peer network, where everyone is allowed to join. In this, every user or node gets a full copy of the blockchain. If someone creates a new block, it is sent to everyone in the network. Each node verifies the block to check if it is tampered or not and then if everything goes right they will add the block to their chain of blocks. If a node changes or tampers any block then the whole copy is sent to all the nodes to verify if the transaction or change was valid then every node will accept the new blockchain or else will reject it. This gives security in data, if any hacker tries to change a block then he has to hack all the nodes to accept the change or change every block. This is quite difficult and thus makes the data more secure. In any centralized database system only the admin can alter the data, i.e. to add, remove and edit any row or column of the data, but in blockchain there is no centralised system, many transactions occur at the same time, so the one doing the transaction makes a new block which consists the details of the transaction. The node that created the block has to prove that the work done qualifies them to get the right to add a new transaction, i.e. a block. This method is a type of consensus method known as Proof-Of-Work.