Our blockchain tutorial will guide you through the intricacies of blockchain technology. We’ll start off with some helpful definitions before taking a deep dive into how this technology works and why it is so important.
So, you’ve decided to take the plunge into blockchain technology. No doubt you took note of how innovative and impactful it is and you want to learn more about it. In this technological age we are living in, that should come as no surprise.
Like most concepts, it would be easy to do a quick Google search and get a definition that is two or three sentences long. Sure, that is one way of understanding what blockchain is, but that only scratches the surface. We are dealing with a piece of technology that is paving the way for an array of fields. Finance, healthcare, government, identity, the list goes on. The bottom line is blockchain applications have the potential to completely transform society.
Could a short definition cover all that? Most likely not. If you want to properly understand what this technology is about, you need to get down to the nitty-gritty. That includes what it consists of, what the popular use cases are, and the problems it seeks to rectify. It is a relatively complex system that may take time for you to fully grasp.
First things first, what is it?
Many consider blockchain to essentially be the backbone of the entire cryptocurrency system. An easy way to define it is as a chain containing an array of blocks that possess crucial information. The intent behind this technique is to timestamp digital documents. By doing this, it becomes impossible for anyone to backdate or tamper with them. The overall purpose of blockchain is to solve the double records issue without needing to involve a central server.
The primary use for blockchain is to ensure a secure transfer of valuable items, such as money, property, and contracts. Moreover, it focuses on doing this without the requirement of a third-party intermediary, like a bank or the government. As soon as data is recorded inside a blockchain, it becomes incredibly difficult to make any changes to it.
The management of the blockchain is typically in the hands of a peer-to-peer (P2P) network. It collectively adheres to a protocol pertaining to the validation of new blocks. Following the recording, alteration of the data in any block is impossible without the alteration of all subsequent blocks. Furthermore, the total collusion of the network majority. Once transactions are in the blockchain, they are permanent and you cannot hack or manipulate them.
It is important to emphasize what blockchain isn’t before moving forward. Blockchain is not Bitcoin; it is the technology behind Bitcoin. Put simply, Bitcoin is the digital token and blockchain is the ledger that keeps track of the token owners’ identities. It is difficult to have Bitcoin without the presence of blockchain. On the other hand, it is possible to have a blockchain without Bitcoin.
There are a variety of features that make blockchain the revolutionary piece of technology that it is. Some of the most important features include the following:
- SHA-256 Hash Function
- Public Key Cryptography
- Distributed Ledger & P2P Network
- Proof of Work (PoW)
- Validation incentives
To better understand how blockchain operates, it is important to learn about these features. Let’s go over each of them one by one.
SHA-256 Hash Function
The core hash algorithm that blockchain technology frequently uses is SHA-256. The primary reason for using a hash is because the output is not necessarily ‘encryption.’ In other words, it is impossible to decrypt back to the original text. It is, instead, a ‘one-way’ cryptographic function. Moreover, it is an established size for any size of the source text.
Let’s use an example to further illustrate this. Suppose we are feeding an input as “Hello World,” “Hello World!”, and “hello world!” Three similar inputs, but each has something that makes them different from the other. Each one gets its own individual hash function. The outputs for each input are the following:
We are feeding the input as “Hello World” and getting the first output. However, by simply adding an “!” at the end, the output completely changes to the second one. Likewise, if we change “H” and “W” to their lowercase forms, then the output value changes to the third one.
Public Key Cryptography
This cryptographic technique assists the user by creating a set of keys. These are what we refer to as a ‘public key’ and a ‘private key’. The user shares the public key with others, whereas the private key is kept, well, private. It functions as a secret that the user keeps. Like with SHA-256, we will use a hypothetical example to better explain this.
Imagine two people, with one being the ‘signer’ and the other the ‘verifier’. If Person A sends bitcoins to Person B, that transaction will have a total of three pieces of information:
- Person B’s bitcoin address (aka. their public key)
- The number of bitcoins that Person A is sending to Person B
- Person A’s bitcoin address (aka. their public key)
All this data, as well as an encrypted digital signature, is sent through the network to receive verification. The ‘digital signature’ is, once again, a hash value stemming from the combination of Person A’s bitcoin address and the amount they are sending. The encryption of this digital signature is done so by the private key. When a miner who needs to verify this transaction receives the data, there are two processes they must do simultaneously:
- The miner takes all the un-encrypted data (the transaction amount and public keys of both Person A and B) and feeds it to a hash algorithm. Doing so will give them a hash value which we shall call ‘Hash 1’.
- They take the digital signature and decrypt it using Person A’s public key to get a hash value. We will call this ‘Hash 2’.
After all of this, let’s say that both Hash 1 and Hash 2 are the same. If this is the case, then it means that this is officially a valid transaction.
Distributed Ledger & P2P Network
Every single person participating in the network has its own copy of the ledger. Before you ask, no, there isn’t a single centralized copy of the ledger. The best way to understand this is by imagining the following scenario. Let’s say that you need to send 10 bitcoins to your friend. What’s more, suppose that your bitcoin balance is 974.65 and your friend has a balance of 37. Your balance will end up being deducted by 10 BTC and that will be credited into your friend’s account.
Blockchain has a unique way of implementing this process. Generally speaking, there aren’t any accounts and balances within the Bitcoin blockchain ledger. Each and every transaction from the first one goes into storage on the ever-growing database that is blockchain. There are blocks that average roughly 2,050 transactions. Furthermore, as of this writing, there are 630,599 blocks in the blockchain with over 500 million transactions.
The distribution of this ledger stretches across all users of the Bitcoin blockchain. Or, in simple terms, the ledger has no central location where it is put into storage. Pretty much everyone on the network owns a copy of the ledger. The true copy, however, is the collection consisting of all the distributed ledgers.
Proof of Work (PoW)
Everyone equally owns the ledger, but this begs the question of who adds blocks to the blockchain. Moreover, how can people place their trust in this person?
Well, for this, we have the popular concept, ‘proof of work’ (PoW). The best way to describe this process is by comparing it to solving a very big puzzle. It requires a ton of computational effort in order to make it work. And who is responsible for carrying this out? People in the Bitcoin network that we refer to as ‘miners’. Obviously they don’t mine in the traditional sense with pickaxes and such. The work that these miners do is to verify the transactions. Additionally, they solve complex mathematical puzzles associated with the block undergoing their creation.
Following an adjustment of the problem’s difficulty, solving a block typically takes about 10 minutes. Miners search for a nonce (mathematical value) that will give the desired hash, which is predetermined. Each block possesses a hash value that is the combination of the following:
- The previous block’s final hash
- Hask value of the transaction data
- The nonce
It is mandatory for the block’s final resulting hash to start with a specific number of trailing zeroes. It is this calculation that determines the nonce, thus satisfying the condition, that ultimately makes mining so computationally expensive.
So, the person who is able to find this nonce is deemed the successful miner. After achieving this, they have free rein to add their block to the blockchain. Through the P2P distributed network, they broadcast their block and in turn, everyone can verify if hashes match. What’s more, they can make updates to their blockchain and move on to solving the next block almost immediately.
The final step of a Bitcoin transaction is giving a reward to the miner responsible for creating the latest block. The blockchain system provides this reward for the validation of the transactions and the maintenance of the Blockchain. At this point in time, the block reward of Bitcoins is 12.5 BTC per block. This is by far the most interesting part of the bitcoin mining process, with the rewards being too enticing to pass up.
Generally speaking, Bitcoin incentives are the only way to generate new currency into the system. Many believe that by the year 2140, all 21 million bitcoins will have finally been mined.
Issues with banking
So, we have gone over what blockchain technology is and its important features. Now we must ask the question of how this came to be. What inspired its initial development?
The growth of blockchain technology, as well as cryptocurrency, has proven itself to be very rapid. So much so that even those who do not have full knowledge about how it works are looking to invest in it.
Both blockchain technology and the cryptocurrencies are fast becoming a parallel platform. One that allows people to start executing their standard transactions. With that in mind, there comes a thought regarding our current banking system. If a new one is slowly replacing what already exists, then surely there must be problems with the current system.
The truth of the matter is any existing system will have at least some issues. Let’s take a look at some of the most common issues with the current banking system.
1 – High transaction fees
Let’s use another Person A/B example to explain this issue. Person A is sending $100 to Person B, but before they can do that, it needs to pass through a trusted third party. It could be a bank or financial service company. Only when the transaction passes through this party can Person B finally receive it. There is the deduction of a transaction fee of 2% from this amount. Therefore, Person B only receives $98 at the end of the transaction.
Admittedly, this does not appear to be a huge amount. However, imagine that you are sending $100,000 instead of $100, then the transaction fees also increase to $2,000. This, as you can probably tell, is a big amount. According to an SNL Financial and CNNMoney report, in 2015, JPMorgan Chase, Bank of America, and Wells Fargo would earn over $6 billion from ATM and overdraft fees.
2 – Double-spending
Double-spending is among the more annoying issues in the digital cash scheme. It’s an error in which the same single digital token is spent two or more times.
In this case, Person A only has $500 in their account. They decide to conduct 2 transactions simultaneously to Person B for $400 and Person C for $500. Now, this transaction would normally not go through because Person A doesn’t have a balance of $900 in their account. However, there is a method to this madness. By duplicating or falsifying the digital token in relation to every digital transaction, they are able to complete these transactions. And they can do without the required balance.
3 – Account hacking and net frauds
In India in 2016, the number of fraud cases connecting to credit/debit cards and Internet banking was close to 15,000. 14,824 cases to be exact. The net amount deriving from these frauds was Rs 77.79 crore. Ro elaborate, Rs 21 crore was from Internet frauds and Rs 41.64 crore was from ATM/debit card frauds.
4 – Financial Crisis and Crashes
If there is one thing we can all agree on it’s that financial crises are a pain. Thanks to the COVID-19 outbreak, we found ourselves in a dire economic situation. Jobs are lost, unemployment went up, it’s all a mess. Unfortunately, it is a recurring mess.
Imagine you give all of your savings to someone you have a lot of faith in only to have them lose it all. Now imagine that situation at a larger scale. That is exactly what happened during the 2007-08 recession. During this time, banks and investment organizations were borrowing heavily and lending it as subprime mortgages to people. Specifically, people who could not pay back these loans. This would result in one of the greatest financial crises to ever occur. A rough estimation indicates that this recession led to losses close to $11 trillion ($11,000,000,000,000) worldwide.
This is just one of the most popular examples of a financial crash. When you think about it, how often do we hear about banks and financial service companies crashing due to internal frauds? Taking this into account, the whole third-party system is something that is dependent on blind trust on the middleman. This blind trust could have disastrous consequences in the long-run if the 2007-08 crash is anything to go by.
Solving these issues
As part of our blockchain tutorial, it’s time now to cover how blockchain applications may help solve the problems in legacy financial systems. How exactly can blockchain technology help mitigate – or outright get rid of – these issues? There are actually an array of solutions that blockchain can provide. Below are just a handful of the ways through which this technology plans to tackle these recurring problems.
1 – Using a decentralized system
A decentralized system is an information system in which no single entity is the sole figure of authority. If we apply it to the context of computing and information technology, decentralized systems take the form of computers in a network.
At its core, the blockchain system follows a decentralized approach. This is especially prevalent when in comparison to banks and financial organizations under the control of central or federal authorities. When it comes to blockchain, everyone who is participating in the system has equal responsibility. Not just for the growth of the system but also for its downfall.
A single entity retaining power does not apply in this case. Instead, everyone who is part of the system holds at least some power.
2 – Public ledgers
There is a ledger that holds the details of every single transaction that happens on the blockchain. It is open and completely accessible to everyone who is in association with the system. Upon joining the network, you will be able to download the complete list of transactions since its inception.
Despite the ledger being publicly accessible, there are some things that participants cannot see. The details of those who are part of the transactions will remain completely anonymous.
3 – Proper verification of every single transaction
In order for a transaction to be official, it will need to undergo verification. Every single transaction will need to have this process done; there are no exceptions. This is through cross-checking the ledger and sending the validation signal of the transaction after a few minutes. By using an array of complex encryption and hashing algorithms, we will see the elimination of the double-spending problem.
4 – Low transaction fees or none at all
Most of the time, the transaction fees are usually not applicable. However, there are certain variants of blockchain that actually implement specific types of minimal transaction fees. Be that as it may, it’s important to remember that these transaction fees are considerably less pricey. Especially when you compare them to the fees that banks and other financial organizations typically entail.
If there is a dire need for the completion of a transaction, then additional transaction fees can be added by the user. Doing so will automatically make verifying the transaction a top priority.
After covering these important features and what blockchain is, hopefully, you have a better understanding of the technology. Moreover, you have a greater appreciation for this innovation. Blockchain is, overall, so much more than the system that powers Bitcoin. As a matter of fact, finance is just one of the many industries blockchain seeks to disrupt and improve.
Moving on with our blockchain tutorial, we now will take a look at different sectors and fields that benefit from blockchain technology. There are many examples, but we will go over some of the more notable use cases.
First, there is the healthcare industry:
- Management for data
- Universal databanks for EMR Health
- QS Data Commons
- Considerably large health data stream analytes
- Digital health wallet smart property
- Health Token
- Contracts that focus primarily on personal development
For finance and accounting, there are these advantages:
- Allowing payment with the use of digital currency
- Payments and remittance
- Decartelized capital markets utilizing a network consisting of the computers on the blockchain
- Inter-divisional accounting
- Clearing, trading, and derivatives
In the government sector, blockchain provides the following:
- Transnational governance services that are personalized
- Voting and propositions P2P bond
- Digitization of documents/contracts, as well as providing proof of ownership for transfers
- Registry and identification
- Tele-attorney service
- IP registration and exchange
- Tax receipts for notary service, plus document registry
Finally, for IOT (Internet of Things), there are these benefits:
- Agricultural and drone sensor networks
- Smart home networks
- Smart home sensors
- Full integration of a smart city
- Self-driving car
- Digital assistants
- Personalized robots and additional robotic component
- Personalized drones
There are three general versions of blockchain: Blockchain 1.0, Blockchain 2.0, and Blockchain 3.0.
- 1.0: Currency – The implementation of distributed ledger technology would lead to its first (not to mention obvious) application: cryptocurrencies. This is what allows financial transactions based on blockchain technology. It is a very handy tool when it comes to currency and payments, and Bitcoin is the most prominent example.
- 2.0: Smart Contracts – The new key concepts are smart contracts. These are essentially small computer programs that reside within the blockchain. They are free computer programs that have automatic executions, checking pre-defined conditions. These include such things as facilitation, verification, and enforcement. It is useful as an alternative for conventional contracts.
- 3.0: DApps – DApps, an abbreviation for ‘decentralized application’, have their backend code running on a decentralized P2P network. A DApp is able to have frontend code and user interfaces in any language that is capable of making a call to its backend. In this sense, it is no different than a traditional app.
Concluding our Blockchain Tutorial
Blockchain provides a strong sense of trust among all participating parties. It is equipped with a feeling of ownership due largely in part to the public and private keys. By having these digital tools in your possession, the user can fulfill requirements surrounding authenticity. Authenticity is an element that is always available with the involvement of a third party or middleman.
Authenticity is arguably nothing without authorization. Moreover, authorization is a pivotal factor in guaranteeing a reliable system. Because blockchain operates on a P2P network, it reduces failure that would otherwise be present due to a centralized system.
We hope that this tutorial gave you more insight into blockchain technology. Now that you have more knowledge on the subject, you can go forward with a better understanding of the system. While there is more to learn about blockchain, this tutorial covers the key parts.