Here, everyone.
Welcome to the course.
In this course, we are going to define the blockchain architecture for your enterprise graded applications
and projects.
But before we go into defining blockchain architecture, we need to understand what blockchain is and
how blockchain functions.
So let's get started by understanding and introducing you to the blockchain.
And from there we will move forward to the blockchain architecture.
On my recent visit to one of the colleges, my first question was, Do you guys know about blockchain?
And out of 250 students in attendance, only four raised their hands.
But when I asked, Do you guys know about Bitcoin?
Almost 95% of the attendees raised their hands.
Blockchain is termed as Bitcoin or cryptocurrencies by layman users, and in a way, blockchain is also
getting a bad name because of the same.
But in reality, blockchain is the technology and the cryptocurrencies are just the mainstream manifestation
of its potential.
Now, before we define blockchain, let's take a small example of how blockchain is solving some real
world difficulties.
Let us assume two individuals, Alice and Bob, who want to transfer money in the traditional way of
transferring money.
A physical transfer of money would take place between Alice and Bob, where they would actually meet
in person at a common place to do so.
Human settlements over long distances have increased with time and have therefore made it difficult
for the people to meet in person and transfer the funds.
Now, with the advancement of technology, instead of meeting in person, we have started providing
digital money to each other by using internet services to transfer the money.
In our example, Alice will send the digital cash to Bob.
But there is a problem with digital money as Bob is not receiving the physical money, Bob cannot be
sure whether Alice is sending the digital money only to him.
Or it could be a case that Alice is also sending the digital copies of the money to different people
at the same time.
Alice could be sending the digital money to Dave, apart from sending the same money to Bob to make
sure that this kind of scenario is not happening within the transaction for Alice and Bob, they decided
that they will appoint one single person who will note down all the transactions in a book.
This will make sure that their network is secure and people who are transferring money are not able
to cheat.
Dave is going to note down all the transactions henceforth.
Moving on with our example.
When Bob sends the digital cash to Carol, then Dave notes down the transaction in the record book.
Similarly, when Carol sends the digital money to Eugene again, Dave notes down the transaction in
the records book.
This is the same process how our banks are working.
But soon the network started to become big and the digital money is being transacted between hundreds
and thousands of people, with Dave noting down all the transactions.
Now another problem came in front that there could be a possibility that Dave has also become money
holder and tries to change some transaction or manifest fake transactions for his benefit.
To avoid such a behavior by a single entity who is in charge of the records?
The whole group who is using the digital cash decided that every single person inside the Digital cash
network will hold the copy of the ledger for recording the transactions.
Now, when Alice sends the digital cash to Bob, then every person inside the system is noting down
the transaction.
Similarly, when Bob is sending the digital money to Carol again, everybody is indicating the transaction
in their copy of the book.
If Dave decides to alter the transactions for his gain, then every one in the network can verify that
the alter transaction has not taken place and somebody is trying to cheat the system.
How this solves the traditional problems, noting down the transactions in a ledger makes sure that
the double spending is not allowed.
If Alice tries to send two copies of digitized money to different people, it can be verified through
the ledger that this is not allowed.
Moreover, it removes the trust we put into a centralized system.
Initially in our network, we were trusting Dave to make sure that everything is working fine in the
system, but now providing the ledger to everyone within the network, we are making sure that the trust
is developed through consensus, where everyone is connected to the network and making sure that the
system is working truthfully.
For example, if Dave decides to cheat the network by changing the transaction in his copy of records
from Dave to Carol to a fraudulent transaction like Alice to Carol on Dave's part, this is to make
sure that his account is never getting deducted for the digital cash.
But everyone inside the network can verify that this transaction has not happened and Dave is trying
to cheat the network.
Finally, they can remove the culprit from the system.
This is how Bitcoin blockchain is solving the traditional problems related to the transfer of finance.
Taking from our example, if we want to define blockchain in simple terms, then we would say it as
a distributed database technology available over a peer to peer network, or in other words, we can
say it's a distributed ledger of all the records or transactions.
Blockchain was initially devised to power Bitcoin, but it has much more significant use than realizing
the cryptocurrencies.
We will see in the next sessions how you can utilize blockchain in different aspects of industries.
Every blockchain which is available in the market is primarily built from three core technical functionalities.
The first one is private key cryptography.
This private key cryptography involves algorithms like SEC and RSA.
For example, Bitcoin and Ethereum are working on SEC algorithm, which is part of Ecdsa umbrella.
SEC algorithm states a curve where mirror points are chosen as a key pair.
The next technical functionality required for the blockchain is a peer to peer network.
A P2P system is devised in such a way that the network participants do not need to trust a centralized
server.
They are connected and creates trust through the consensus.
In the example we discussed at the start of this session, we created a peer to peer network by distributing
the copy of the ledger to everyone in the system.
And the third most important technical aspect for blockchain is the blockchain protocols.
Protocols are used to define how your chain will operate.
For example, the Bitcoin defines that a new block will be added about every ten minutes.
A reward will be distributed for confirmation of the blocks and the block size could not go up to one
MB.
Other blockchains have some different protocols.
Some blockchains might also include protocols for assets and data.
Now let's go and understand blockchain with the help of some real world analogies.