Digital Notes - 1
Digital Notes - 1
DIGITAL NOTES ON
BLOCK CHAIN TECHNOLOGY
B. TECH – 7 Sem
(2024-25)
DEPARTMENT OF E N G I N E E R I N G & INFORMATION TE C H N O L O G Y
1
Blockchain UNIT-1 SEM-7
BLOCKCHAIN TECHNOLOGY
CLO 1 Develop a workable knowledge of basic concepts of blockchain technology and its
underlying mechanisms.
CLO 2 Understand cryptographic primitives in blockchain and its impact on
implementation related decisions.
CLO 3 Review the principles behind various consensus mechanism models
2
Blockchain UNIT-1 SEM-7
Course Content:
Sr. Topics Teaching
Weightage
Hours
3
Blockchain UNIT-1 SEM-7
UNIT-I
➢ INTRODUCTION: -
• Blockchain is a buzzword in today's technology and this technology is described as the most disruptive
technology of the decade. Thus, Blockchain is used for the secure transference of items like money,
contracts, property rights, stocks, and even networks without any requirement of Third-Party Intermediaries
like Governments, banks, etc. Once the data is stored in the Blockchain it becomes very difficult to
manipulate the stored data. A Blockchain is a Network Protocol like SMTP. However, Blockchain cannot
be run without the Internet. Blockchain is useful in many areas like Banking, Finance, Healthcare,
Insurance, etc.
• Definition: - A blockchain is an open, distributed ledger that can record transactions between two parties
efficiently and in a verifiable and permanent way without the need for a central authority.
• Blockchain can be defined as the Chain of Blocks that contain some specific Information. Thus, a
Blockchain is a ledger i.e. file that constantly grows and keeps the record of all transactions permanently.
This process takes place in a secure, chronological (Chronological means every transaction happens after
the previous one) and immutable way. Each time when a block is completed in storing information, a new
block is generated.
4
Blockchain UNIT-1 SEM-7
• Blockchain enhances trust across a business network. It’s not that you can’t trust those who you
conduct business with it’s that you don’t need to when operating on a Blockchain network.
Blockchain builds trust through the following five attributes:
1. Distributed: The distributed ledger is shared and updated with every incoming transaction among
the nodes connected to the Blockchain. All this is done in real time as there is no central server
controlling the data.
2. Secure: There is no unauthorized access to Blockchain made possible through Permissions and
Cryptography.
3. Transparent: Because every node or participant in Blockchain has a copy of the Blockchain data,
they have access to all transaction data. They themselves can verify the identities without the need
for mediators.
4. Consensus-based: All relevant network participants must agree that a transaction is valid. This is
achieved through the use of consensus algorithms.
5. Flexible: Smart Contracts which are executed based on certain conditions can be written into the
platform. Blockchain Networks can evolve in pace with business processes.
➢ History of Blockchain:
• In 1991, researcher scientists named Stuart Haber and W. Scott Stornetta introduce Blockchain
Technology. These scientists wanted some Computational practical Solution for time-stamping the
digital documents so that they couldn't be tempered or misdated. So, both scientists together developed
a system with the help of Cryptography. In this System, the time-stamped documents are stored in
a Chain of Blocks.
• After that in 1992, Merkle Trees formed a legal corporation by using a system developed by Stuart
Haber and W. Scott Stornetta with some more features. Hence, Blockchain Technology became efficient
to store several documents to be collected into one block. Merkle used a Secured Chain of Block which
stores multiple data records in a sequence. However, this Technology became unused when Patent came
into existence in 2004.
5
Blockchain UNIT-1 SEM-7
• After that in 2008, Satoshi Nakamoto conceptualized the concept of "Distributed Blockchain"
under his white paper: "A Peer-to-Peer Electronic Cash System". He modified the model of
Merkle Tree and created a system that is more secure and contains the secure history of data
exchange. His System follows a peer- to-peer network of time stamping. His system became
so useful that Blockchain become the backbone of Cryptography.
6
Blockchain UNIT-1 SEM-7
• Blockchain is a technology where multiple parties involved in communication can perform different
transactions without third-party intervention. Verification and validation of these transactions are carried
out by special kinds of nodes.
• Header: It is used to identify the particular block in the entire blockchain. It handles all blocks in
the blockchain. A block header is hashed periodically by miners by changing the nonce value as
part of normal mining activity, also Three sets of block metadata are contained in the block header.
• Previous Block Address/ Hash: It is used to connect the i+1th block to the ith block using the hash. In
short, it is a reference to the hash of the previous (parent) block in the chain.
• Timestamp: It is a system verify the data into the block and assigns a time or date of creation for digital
documents. The timestamp is a string of characters that uniquely identifies the document or event and
indicates when it was created.
• Nonce: A nonce number which uses only once. It is a central part of the proof of work in the block. It
is compared to the live target if it is smaller or equal to the current target. People who mine, test, and
eliminate many Nonce per second until they find that Valuable Nonce is valid.
• Merkel Root: It is a type of data structure frame of different blocks of data. A Merkle Tree stores all
the transactions in a block by producing a digital fingerprint of the entire transaction. It allows the users
to verify whether a transaction can be included in a block or not.
7
Blockchain UNIT-1 SEM-7
1. Node: Nodes are network participants and their devices permit them to keep track of the distributed
ledger and serve as communication hubs in various network tasks. A block broadcasts all the network
nodes when a miner looks to add a new block in transactions to the blockchain.
2. Transactions: A transaction refers to a contract or agreement and transfers of assets between parties. The
asset is typically cash or property. The network of computers in blockchain stores the transactional data as
copy with the storage typically referred to as a digital ledger.
3. Block: A block in a blockchain network is similar to a link in a chain. In the field of cryptocurrency, blocks
are like records that store transactions like a record book, and those are encrypted into a hash tree. There
are a huge number of transactions occurring every day in the world. It is important for the users to keep
track of those transactions, and they do it with the help of a block structure.
4. Chain: Chain is the concept where all the blocks are connected with the help of a chain in the whole
blockchain structure in the world. And those blocks are connected with the help of the previous block hash
and it indicates a chaining structure.
5. Miners: Blockchain mining is a process that validates every step in the transactions while operating all
cryptocurrencies. People involved in this mining they called miners. Blockchain mining is a process to
validate each step in the transactions while operating cryptocurrencies.
6. Consensus: A consensus is a fault-tolerant mechanism that is used in computer and blockchain systems to
achieve the necessary agreement on a single state of the network among distributed processes or multi-
agent systems, such as with cryptocurrencies. It is useful in record keeping and other things.
8
Blockchain UNIT-1 SEM-7
✓ There are different kinds of consensus mechanism algorithms, each of which works on different
principles:
• Proof of Work (PoW): Proof of Work required a stakeholder node to prove that the work is done and
submitted by them certifying them to receive the right to add new transactions in the blockchain.
• Proof of Stake (PoS): The proof of Stake is also a common consensus algorithm that evolved as a low-cost
low-energy-consuming, low-energy-consuming alternative for the PoW algorithm. For providing the
responsibilities the public ledger provides by the virtual currency token like Bitcoin and Ethereum.
• Proof of Capacity (PoC): Proof of Capacity (PoC) allow sharing of memory space of the nodes in the
blockchain network.
• Proof of Elapsed Time (PoET): It encrypts the passage of time cryptographically to reach an agreement
without expending many resources.
➢ Types of Blockchain:
1. Public Blockchain:
• A public blockchain is a concept where anyone is free to join and take part in the core activities of
the blockchain network. Anyone can read, write, and audit the ongoing activities on a public
blockchain network, which helps to achieve the self-determining, decentralized nature often
authorized when blockchain is discussed. Data on a public blockchain is secure as it is not possible
to modify once they are validated.
• The public blockchain is fully decentralized, it has access and control over the ledger, and its data is
not restricted to persons, is always available and the central authority manages all the blocks in the
chain. There is publicly running all operations. Due to no one handling it singly then there is no need
to get permission to access the public blockchain. Anyone can set his/her own node or block in the
network/ chain.
• After a node or a block settled in the chain of the blocks, all the blocks are connected like peer-to-
peer connections. If someone tries to attack the block then it forms a copy of that data and it is
accessible only by the original author of the block.
✓ Advantages:
• A public network operates on an actuate scheme that encourages new persons to join and keep the
network better.
• There is no agreement in the public blockchain.
• This means that a public blockchain network is immutable.
• It has Rapid transactions.
9
Blockchain UNIT-1 SEM-7
✓ Disadvantages:
• Public blockchain can be costly in some manner.
• The person need not give identity, that’s why there is a possibility of corruption of the block if it is in
under attack.
• Processing speed is sometimes slow and It has Integration issues.
2. Private Blockchain: -
• Miners need permission to access a private blockchain. It works based on permissions and controls,
which give limit participation in the network. Only the entities participating in a transaction will have
knowledge about it and the other stakeholders not able to access it. By it works on the basis of
permissions due to this it is also called a permission-based blockchain.
• Private blockchains are not like public blockchains it is managed by the entity that owns the network.
A trusted person is in charge of the running of the blockchain it will control who can access the
private blockchain and also controls the access rights of the private chain network. There may be a
possibility of some restrictions while accessing the network of the private blockchain.
✓ Advantages:
• In a private blockchain, users join the network using the invitations and all are verified.
• Only permitted users/ persons can join the network.
• Private Blockchain is partially immutable.
✓ Disadvantages:
• A private blockchain has trust issues, due to exclusive information being difficult to access it.
• As the number of participants increases, there is a possibility of an attack on the registered users.
10
Blockchain UNIT-1 SEM-7
3. Consortium Blockchain
• A consortium blockchain is a concept where it is permissioned by the government and a group of
organizations, not by one person like a private blockchain. Consortium blockchains are more
decentralized than private blockchains, due to being more decentralized it increases the privacy and
security of the blocks. Those like private blockchains connected with government organizations
blocks network.
• Consortium blockchains is lies between public and private blockchains. They are designed by
organizations and no one person outside of the organizations can gain access. In Consortium
blockchains all companies in between organizations collaborate equally. They do not give access
from outside of the organizations/ consortium network.
✓ Advantages:
• Consortium blockchain providers will always try to give the fastest output as compared to public
blockchains.
• It is scalable.
• A consortium blockchain is low transaction costs.
✓ Disadvantages:
• A consortium blockchain is unstable in relationships.
• Consortium blockchain lacks an economic model.
• It has flexibility issues.
11
Blockchain UNIT-1 SEM-7
12
Blockchain UNIT-1 SEM-7
• One of the famous uses of Blockchain is Bitcoin. Bitcoin is a cryptocurrency and is used to
exchange digital assets online. Bitcoin uses cryptographic proof instead of third-party trust for two
parties to execute transactions over the Internet. Each transaction protects through a digital signature.
➢ Benefits of blockchain:
o Numerous benefits of blockchain technology are being discussed in the industry and proposed by
thought
leaders around the world in blockchain space. The top benefits are listed and discussed as follows.
Decentralization:
• This is a core concept and benefit of blockchain. There is no need for a trusted third party or
intermediary to validate transactions; instead, a consensus mechanism is used to agree on the
validity of transactions.
Transparency and trust:
• As blockchains are shared and everyone can see what is on the blockchain, this allows the
system to be transparent and as a result trust is established. This is more relevant in scenarios
such as the disbursement of funds or benefits where personal discretion should be restricted.
Highly secure:
• All transactions on a blockchain are cryptographically secured and provide integrity.
13
SEM-7 UNIT-1 Blockchain
Immutability:
• Once the data has been written to the blockchain, it is extremely difficult to change
it back. It is not truly immutable but, due to the fact that changing data is extremely
difficult and almost impossible, this is seen as a benefit to maintaining an immutable
ledger of transactions.
High availability:
• As the system is based on thousands of nodes in a peer-to-peer network, and the data
is replicated and updated on each and every node, the system becomes highly
available. Even if nodes leave the network or become inaccessible, the network as a
whole continues to work, thus making it highly available.
Cost saving:
• As no third party or clearing houses are required in the blockchain model, this can
massively eliminate overhead costs in the form of fees that are paid to clearing houses
or trusted third parties.
• The blockchain network maintains its high level of security through private keys.
It comes in handy when you validate a blockchain address. Moreover, when you
open a crypto wallet, you get a private key. It is a password that allows you to
withdraw funds from your wallet. By chance, if you lose this key, you cannot
withdraw funds from your account. So, you need to store multiple copies of it just
so that if you lose the original one, you can rely on one of the copies.
14
SEM-7 UNIT-1 Blockchain
4. Environmental impacts
• Mining, minting and validating transactions require high-powered systems to run
24/7. Apart from heavy investments, these processes require a lot of power. This
can lead to serious environmental consequences.
5. Storage problems
• As the number of users increases, so will the data; hence, the hard disk space will
also need an upgrade. A time may come when a blockchain's total amount of data
may exceed the available hard disk sizes.
6. Immutability
• Once you enter information on a blockchain, it becomes unchangeable. If any
errors or information need updating, it is simply impossible to do so. On the flip
side, this feature is an advantage of blockchain, as the data cannot be violated in
any way. But there are always two sides to a coin, and you must be aware of
both.
15
SEM-7 UNIT-1 Blockchain
➢ Application of Blockchain
16
SEM-7 UNIT-1 Blockchain
➢ What is Decentralization:
• There is no Central Server or System which keeps the data of the Blockchain.
• The data is distributed over Millions of Computers around the world which are
connected to the Blockchain. This system allows the Notarization of Data as it is
present on every Node and is publicly verifiable.
• Decentralization is a core benefit and service provided by blockchain technology. By
design, blockchain is a perfect vehicle for providing a platform that does not need
any intermediaries and that can function with many different leaders chosen via
consensus mechanisms. This model allows anyone to compete to become the
decision-making authority. A consensus mechanism governs this competition, and
the most famous method is known as Proof of Work (Pow).
• A decentralized system is a type of network where nodes are not dependent on a single
master node; instead, control is distributed among many nodes. This is analogous to a
model where each department in an organization is in charge of its own database
server, thus taking away the power from the central server and distributing it to the
sub-departments, who manage their own databases.
• A significant innovation in the decentralized paradigm that has given rise to this
new era of decentralization of applications is decentralized consensus. This
mechanism came into play with Bitcoin, and it enables a user to agree on something
via a consensus algorithm without the need for a central, trusted third party,
intermediary, or service provider.
➢ What is centralization:
• A centralized system is one in which all decision-making and control reside in one
central authority or entity. In other words, power is concentrated in a single location or
group of individuals, who make all the key decisions that affect the entire system.
• Centralized systems are conventional (client-server) IT systems in which there is a
single authority that controls the system, and who is solely in charge of all operations
on the system. All users of a centralized system are dependent on a single source of
service.
• The majority of online service providers, including Google, Amazon, eBay, and
Apple's App Store, use this conventional model to deliver services.
17
SEM-7 UNIT-1 Blockchain
18
SEM-7 UNIT-1 Blockchain
➢ Blockchain nodes: -
• A node is a computer connected to the Blockchain Network. Node gets connected with
Blockchain using the client. The client helps in validating and propagating
transactions onto the Blockchain.
• When a computer connects to the Blockchain, a copy of the Blockchain data gets
downloaded into the system and the node comes in sync with the latest block of data
on Blockchain. The Node connected to the Blockchain which helps in the execution of
a Transaction in return for an incentive is called Miners.
19
SEM-7 UNIT-1 Blockchain
A comparison between centralized and decentralized systems (networks/applications) is shown in the following table:
Fault tolerance Basic, single point of failure Highly tolerant, as service is replicated
Collusion Basic, because it's under the control of a Highly resistant, as consensus
resistance group or even single individual algorithms ensure defense against
adversaries
20
SEM-7 UNIT-1 Blockchain
➢ Distributed Ledger: -
• A blockchain is a digital ledger of transactions that are distributed across the entire
network of computers (or nodes) on the blockchain. Distributed ledgers use
independent nodes to record, share, and synchronize transactions in their respective
electronic ledgers instead of keeping them in one centralized server.
• A blockchain uses several technologies like digital signatures, distributed networks,
and encryption/ decryption methods including distributed ledger technology to
enable blockchain applications.
• Blockchain is one of the types of DLT in which transactions are recorded with an
unchangeable cryptographic signature called a hash. That is why distributed ledgers
are often called blockchains.
➢ Advantages Of Distributed Ledger Technology: -
21
SEM-7 UNIT-1 Blockchain
22
SEM-7 UNIT-1 Blockchain
➢ Immutable ledger
• An immutable ledger is a record-keeping system where the data entered can’t be
altered, tampered with, or deleted. It ensures that all transactions or entries made in
the ledger are permanently recorded and maintained in their original state, creating a
transparent and trustworthy record of events. Immutable ledgers are used in finance,
supply chain management, and digital currencies. One well-known example of an
immutable ledger is blockchain.
23
SEM-7 UNIT-1 Blockchain
Components of Blockchain:
24
SEM-7 UNIT-1 Blockchain
25