Blockchain is the chain of blocks that comprises data. This technology was initially defined by a group of researchers and was intended to timestamp digital documents so that they could not be tampered with. However, it went totally unused until it was adopted by Satoshi Nakamoto in 2009 to create a digital cryptocurrency called Bitcoin. A blockchain is a distributed ledger system that is completely open to anyone. It's an enthralling property. Once some information is recorded inside the blockchain, it becomes very tough to modify it.
Let’s learn more about the block. Each block contains:
Data - The data that is stored inside a block depending on the type of blockchain. For example, the Bitcoin blockchain stores transaction details such as sender, receiver, and bitcoin amount.
Hash - A block's hash is similar to a fingerprint in that each block has a unique hash code, just as each person has a unique fingerprint. Once the block has been created, its hash can be calculated. Changing something inside the block will make the block’s hash change, so, in other words, hashes are very useful for detecting changes in the block. If the hash of a block changes, it is no longer the same block.
Hash of the previous block - This effectively creates a chain of blocks and it’s this technique that makes the blockchain very secure. For instance, in a chain of three blocks, A, B, and C, each block has its own unique hash as well as a hash for the previous block. Like B will have the hash of A, C will have a hash of B. If someone tampers with block B, the hash changes, and block C, which has the hash of the previous B block, is no longer detected. Therefore, the whole chain becomes irrelevant. Accordingly, changing a single block will make all the following blocks in the chain invalid.
The first block is rather special. We cannot call this block a hash of the previous block, and hence, the name of the first block in each blockchain is called the genesis block.
Security of Blockchain - Since using hashes is not enough to prevent tampering, computers nowadays are very fast. Every second, hundreds of thousands of hashes can be calculated. Therefore, it will be easy to tamper with one block and recalculate all the hashes of the other blocks to make the blockchain valid again. The Blockchain has made itself more secure by incorporating the following steps:
Proof of work – It is a method that delays the formation of the block. Their tagline is "Slow and Steady" because it takes approximately 10 minutes to calculate the required proof of work and to append a new block to the chain. This mechanism makes it very hard to tamper with the block because if you tamper with one block, you need to calculate again the proof of work for all the subsequent blocks in the chain. So, the security of a blockchain evolves from the creative use of hashing and the "Proof of work" mechanism.
Distributed System - It is a mechanism for increasing the security of the Blockchain by utilizing the globalized internet and computer networks. Instead of using a central entity to manage the chain, Blockchain uses peer to peer network in which everyone is allowed to join. When someone joins this network, the person gets a full copy of the blockchain. Then the node can use this to verify whether everything is in order or not.
Each block will then be sent to everyone on the blockchain network. Each node then identifies and verifies the hash code of the previous block to ensure that the block has not been tampered with. If everything checks out on each node, then this block will be added to the blockchain.
A consensus is built by all the nodes in the network to agree about which blocks are valid and which ones aren’t. The other nodes will dismiss the tampered blocks. In order to effectively tamper with the blockchain, you need to tamper with all the blocks on the chain, redo the proof of work for every block and take control of more than 50% of the P2P (peer to peer) network. Only then the tampered block will be accepted by the rest of the chain, which is almost impossible to do.
Smart Contracts - Nick Szabo invented the smart contract in 1997, long before Bitcoin was invented. He is a multi-talented scholar of law, computer scientist and cryptographer. One of the recent developments in the Blockchain system is the creation of smart contracts. Smart contracts are somewhat similar to the real contracts. The major difference is that they are completely digital. It is a small computer program that is stored inside a blockchain.
These are simple programs stored in the chain and used to automatically exchange coins when certain conditions are met. The most common usage of Smart Contracts are:
For example, Kickstarter is a crowd funding platform where investors send money to fund certain ideas and start-ups. Currently, Kickstarter is a mediator, which implies that if a company wants an "X" amount of money. When the money has been collected from the investor, the funds will then be transferred to the start-up or organization by Kickstarter. In return, the organization is required to pay Kickstarter its fee. When the required amount is not collected, then the money will be transferred back to the investors. It’s a trust-based structure. Similarly, it can be replicated over the Blockchain. It might have some strong advantages:
Blockchain Application - The development of blockchain technology has increased the interest of many people. This technology will be utilized for:
Cryptocurrency is talked worldwide but very a few what exactly it is. Currencies have been a very important part of man’s economic life. Previously, it was the Barter System, then precious metals such as gold, and, since the last century, world transactions have been fulfilled using the US Dollar as a constant currency for trade. Now, to understand this concept of currency, we have to understand how the currency works. Currencies all over the world operate in a trust-based system, with a centralized system monitoring and controlling them. For example, in the United States, it is the Federal Reserve Bank, while in India, it is the Reserve Bank of India, and each country has its own system.
Each country’s Central Bank is called the Reserve Bank because they store Forex (Foreign Exchange reserves) to make their country’s economy viable. Now, the Central Bank or Reserve Bank, based on global supply and demand, maintains its Forex. Since, it has been managed by officers and, in some cases, corrupt governments, almost once in every 10 years, due to the mismanagement of paper records and on-ground realities, the global economy experienced bent. To solve this problem, cryptographers wanted to decentralize the currency system, but they couldn't come up with a suitable and trustworthy network for the system for years.
Satoshi Nakamoto in the year 2009, finally devised a system that is immutable, unbreakable, globalized and decentralized; the Blockchain and Bitcoin.
Cryptocurrency is actually a medium of exchange and is known as virtual currency. Cryptocurrency is comparable to real-world currencies, except any physical personification. It also uses cryptography to work its way. It also has a limit on the number of units that can exist. For a bitcoin, it exists at 21 million. We can easily determine the transfer of funds with the hashes algorithm that bitcoin uses. It can be used to know whether the transaction is valid or not.
In Bitcoin, a new block has to be added to the chain. The miner will then be rewarded with a bitcoin. This is the only way that bitcoin can be generated.
Cryptography is a way of using encryption and decryption to safeguard communication in the presence of third parties with malicious intent.
It consists of:
Transaction detail - To whom you might want to send bitcoin and how many?
Hashing Algorithm – Bitcoin uses the SHA256 algorithm, which gives the advantage that the transaction settlement takes 10 minutes to be recorded. Once recorded, no-one will be able to tamper with it.
Signature Algorithm - A transaction passes through the signature of the user’s algorithm with the user’s private key. This is done to uniquely recognize the user.
Output Distribution - The transaction details are then sent across the Blockchain network to be verified using the sender's public key.
Verification - "Users" who check and verify the transaction, whether it’s valid or not, are called miners.
Furthermore, once the transaction has been verified, it can be added to the Blockchain and cannot be changed again.
At the moment, the two most prominent cryptocurrencies are:
Ethereum – It works on a Blockchain network as it is a cryptocurrency that follows a hashing algorithm and can only be carried out in an Ethereum ecosystem or network. The average transaction time for Ethereum is 20 seconds. It also works as a Smart Contract, which means a transaction will only happen only after certain conditions are met.
Bitcoin - Bitcoin is a widely accepted and secure cryptocurrency. It follows a blockchain system and a hashing algorithm. An average Bitcoin transaction needs approximately 10 minutes to complete. When a person records one transaction and obtains the hash, they are rewarded with Bitcoins, which is a process that is known as Bitcoin mining. When it was first introduced in the year 2009, it was clear that there would be 21 million Bitcoins that could be gained only through the Bitcoin mining process. Currently, we have 18 million Bitcoins.
Future & Debates - Currently, many people are in favor of cryptocurrencies and some are not. Critics say this currency needs to be regulated and some believe it is a Ponzi scheme. While for many others, it is the currency of the future. The answer depends on how you analyze the information.