Module-1 What Is Block: Private Key Blockchain Network

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 34

Module-1

What is block
A block in a blockchain is a file that stores and encrypts information, such as a set of
transactions on a blockchain network. Blocks are linked using cryptography and are a
permanent record that cannot be changed or removed without altering the preceding or
following blocks.

Each block has three key attributes:


o Block number: Blocks are numbered sequentially from 0.
o Block hash: A unique fingerprint that identifies the block and the transactions contained
within it.
o Transaction count: The number of transactions in the block

What is bitcoin
 Bitcoin is a global Peer-to-Peer currency that is designed for the Internet. It is
modeled after gold and behaves like cash online, and can be used by anyone.
 It has no central authority, and is deflationary in nature.
 There will only be a total of 21 Million Bitcoins created, and or mined between now
and the year 2140.
 The currency is divisible by 8 decimal places.
(฿.00000001)

How do you get Bitcoins?


There are currently four methods of acquiring Bitcoins.
1. Mining (Requires large investment)
2. Wiring in fiat currency to an BTC exchange.
3. Buying from an individual.
4. Selling items for BTC

What is wallet
 Bitcoins are stored in what are called wallets.
 The primary function of a crypto wallet is to store your private key, which is
necessary to transact on any blockchain network.
 A wallet is a randomly generated string of numbers and consists of two parts:
the public key and private key.
 Example of a public key: 14GabW85FUMQy62CMWLCToQLo81w7iXL2x
 The second half of the Bitcoin wallet is what is known as the private key.
 The reason it is called a private key is that it is intended that only you, the wallet
owner, has access to it.
 ALWAYS KEEP YOUR PRIVATE KEY PRIVATE!

WHAT IS CRYPTOCURRENCY (CLASSWORK)


WHAT IS BLOCKCHAIN TECHNOLOGY(CLASSWORK)

MODULE-1

BLOCKCHAIN INTRODUCTION
 Blockchain is a constantly growing ledger that keeps a permanent record of all the
transactions that have taken place in a secure, chronological, and immutable way.
 It can be used for the secure transfer of money, property, contracts, etc. without
requiring a third-party intermediary such as bank or government.
 Blockchain is a software protocol, but it could not be run without the Internet (like
SMTP is for email).

o Ledger: It is a file that is constantly growing.


o Permanent: It means once the transaction goes inside a blockchain, you can
put up it permanently in the ledger.
o Secure: Blockchain placed information in a secure way. It uses very advanced
cryptography to make sure that the
o information is locked inside the blockchain.
o Chronological: Chronological means every transaction happens after the
previous one.
o Immutable: It means as you build all the transaction onto the blockchain, this
ledger can never be changed.

How Does a Blockchain Work?

1. Facilitating a transaction:

A new transaction enters the blockchain network. All the information that needs to be
transmitted is doubly encrypted using public and private keys.

2. Verification of transaction:
The transaction is then transmitted to the network of peer-to-peer computers distributed
across the world.

All the nodes on the network will check for the validity of the transaction like if a sufficient
balance is available for carrying out the transaction.

3. Formation of a new block:

In a typical blockchain network there are many nodes and many transactions get verified at
a time.

Once the transaction is verified and declared a legitimate transaction, it will be added to the
transaction pool.

All the verified transactions at a particular node form a transaction pool and such multiple
transaction pools form a block.

4. Consensus Algorithm:

The nodes that form a block will try to add the block to the blockchain network to make it
permanent. But if every node is allowed to add blocks in this manner then it will disrupt the
working of the blockchain network.

To solve this problem, the nodes use a consensus mechanism to ensure that every new
block that is added to the Blockchain is the one and only version of the truth that is agreed
upon by all the nodes in the Blockchain, and only a valid block is securely attached to the
blockchain.

The node that is selected to add a block to the blockchain will get a reward and hence we
call them “miners”. The consensus algorithm creates a hash code for that block which is
required to add the block to the blockchain.

5. Addition of the new block to the blockchain:

After the newly created block has got its hash value and is authenticated, now it is ready to
be added to the blockchain.

In every block, there is a hash value of the previous block and that is how the blocks are
cryptographically linked to each other to form a blockchain. A new block gets added to the
open end of the blockchain.

6. Transaction complete:

As soon as the block is added to the blockchain the transaction is completed and the details
of this transaction are permanently stored in the blockchain. Anyone can fetch the details of
the transaction and confirm the transaction.
example:

Let’s say Jack and Phil are two nodes on the bitcoin blockchain network who wants to carry
out a transaction between them.

Step 1: Facilitating the transaction: Jack wants to send 20 BTC to Phil via the Blockchain
network.

Step 2: Verification of transaction: The message for verification will be sent to all the
nodes on the network. All the nodes will check the important parameters related to the
transaction like Does Jack has sufficient balance i.e. at least 20BTC to perform the
transaction. Is Jack a registered node? Is Phil a registered node? After checking the
parameters the transaction is verified.

Step 3: Formation of a new block: A number of verified transactions stack up in mempools


and get stored in a block. This verified transaction will also get stored in a block.

Step 4: Consensus algorithm: Since here we are talking about bitcoins so the Proof-of-
Work consensus algorithm will be used for block verification. In proof-of-work, the system
assigns the target hash value to a node, and according to this, it must come up with a hash
for the new block. The node has to calculate the hash value for the new block that is less
than the target value. If two or more miners mine the same block at the same time, the
block with more difficulty is selected. The others are known as stale blocks. Mining usually
rewards miners with blockchain currency. In this case, the blockchain currency is bitcoin.

Step 5: Addition of the new block in the blockchain: After the newly created block has got
the hash value and authentication through proof-of-work only then it will be added to the
network and the transaction will mark as complete. Phil will receive 20 BTC from Jack.
The new block will be linked to the open end of the blockchain.

Step 6: Transaction complete: As soon as the block is added to the blockchain, the
transaction will take place and 20 BTCs will get transferred from Jack’s wallet to Phil’s
wallet. The details of the transaction are permanently secured on the blockchain.

Anyone on the network can fetch the information and confirm the transaction. This will
help to keep track of all the transactions and to verify whether any user is trying to double
spend. For example, if Jack tries to carry out a transaction in the future, the rest of the
nodes can check Jack’s past transaction records to check whether Jack has enough balance
to carry out the current transaction. If there is enough balance then the transaction will be
approved.
Blockchain vs Bitcoin

Blockchain is created by peter Smith, Ben Reeves and Nicolas Cary

Bitcoin is created by Satoshi Nakamoto


APPLICATIONS OF BITCOIN(7-8 points)
1. Supply Chain:
Blockchain plays a significant role in supply chains, especially as it includes a list of
diverse entities and processes. In the supply chain, the blockchain enables greater
control over the supply chain and fast delivery of goods.

Another advantage is the visibility of the entire process along with accessible tracking
of Bitcoins and products throughout the supply chain.

A great example can be learned from the partnership of corporations like Abu Dhabi
National Oil Company with IBM. It uses blockchain in Oil supply management.
Blockchain is even used in the fashion industry- it increases transparency in clothes
production and allows customers to select brands sustainable and ethical in their
work.

2. Healthcare:
Bitcoin's blockchain can securely store and manage patient records.
It ensures data integrity(no modification), privacy(no one should access our data), and
accessibility across healthcare providers.
3. Digital Identity:
Bitcoin's decentralized nature can enable the development of self-sovereign identity
systems, empowering individuals to control and manage their digital identities
securely.
4. Voting
If personal identity information is held on a blockchain, that puts us just one step
away from also being able to vote using blockchain technology. Using blockchain
technology can make sure that nobody votes twice, only eligible voters are able to
vote, and votes cannot be tampered with. What's more, it can increase access to voting
by making it as simple as pressing a few buttons on your smartphone. At the same
time, the cost of running an election would substantially decrease.
5. Food safety
Bitcoin's blockchain can be utilized to track and verify the origin of food products,
helping to prevent fraud, contamination in the food, and ensure food safety .
6. Energy Market
Bitcoin's blockchain can enable peer-to-peer energy trading platforms, allowing
individuals to buy, sell, and exchange renewable energy resources directly, thereby
decentralizing and democratizing the energy market.
7. Real Estate
Real estate transactions require a ton of paperwork to verify financial information and
ownership and then transfer deeds and titles to new owners. Using blockchain
technology to record real estate transactions can provide a more secure and accessible
means of verifying and transferring ownership. That can speed up transactions, reduce
paperwork, and save money.
8. Money transfers
Money transfers using blockchain can be less expensive and faster than using existing
money transfer services. This is especially true of cross-border transactions, which are
often slow and expensive. Even in the modern U.S. financial system, money transfers
between accounts can take days, while a blockchain transaction takes minutes.
9. Lending
Using blockchain, lenders can make loans that are backed by collateral, like property
or assets, through smart contracts. These contracts automatically enforce terms like
making payments, requesting more collateral if needed, or closing the loan and
returning collateral. This makes the loan process quicker and cheaper, allowing
lenders to offer more attractive rates to borrowers.
10. Insurance
Using smart contracts on a blockchain can provide greater transparency for customers
and insurance providers. Recording all claims on a blockchain would keep customers
from making duplicate claims for the same event. Furthermore, using smart contracts
can speed up the process for claimants to receive payments.
11. Gambling
The gambling industry can use blockchain to provide several benefits to players. One
of the biggest benefits of operating a casino on the blockchain is the transparency it
provides to potential gamblers. Since every transaction is recorded on the blockchain,
bettors can see that the games are fair and the casino pays out. Furthermore, by using
blockchain, there's no need to provide personal information, including a bank account,
which may be a hurdle for some would-be gamblers. It also provides a workaround
for regulatory restrictions since players can gamble anonymously and the
decentralized network isn't susceptible to government shutdown.
12. Data storage
Adding blockchain technology to a data storage solution can provide greater security
and integrity. Since data can be stored in a decentralized manner, it will be more
difficult to hack into and wipe out all the data on the network, whereas a centralized
data storage provider may only have a few points of redundancy. It also means greater
access to data since access isn't necessarily reliant on the operations of a single
company. In some cases, using blockchain for data storage may also be less
expensive.

Public and private key basics


Cryptography: It is the study and practice of techniques for secure communication in the
presence of third parties called adversaries.
 It deals with developing and analyzing protocols that prevents malicious third
parties from retrieving information being shared between two entities.
Plaintext: original message to be encrypted or original message to be communicated
between sender and receiver
Cipher text: the encrypted message or encoded format of the original message that cannot
be understood by humans
Decryption: the conversion of cipher text to plain text.
Enciphering or encryption: the process of converting plaintext into ciphertext.
Private Key: In the Private key, the same key (secret key) is used for encryption and
decryption. In this key is symmetric because the only key is copied or shared by another party
to decrypt the cipher text. It is faster than public-key cryptography.
Public Key:
In a Public key, two keys are used one key is used for encryption and another key is used for
decryption. One key (public key) is used to encrypt the plain text to convert it into cipher text
and another key (private key) is used by the receiver to decrypt the cipher text to read the
message.

Cryptography

o Some security mechanisms listed in the previous section can be implemented using
cryptography.

o Cryptography, a word with Greek origin, means “secret writing”.

o However, we use the term to refer to the science and art of transforming messages to
make them secure and immune to attacks.

o Although in the past cryptography referred only to the encryption and decryption of
messages using secret keys, today it is defined as involving three distinct
mechanisms: symmetric-key encripherment, asymmetric-key encripherment, and
hashing. We will briefly discuss these three mechanisms here.

 Symmetric-key Encipherment/private key cryptography [important]

o This type of cryptography involves the use of a single key to encrypt and decrypt
data.

o Both the sender and receiver use the same key, which must be kept secret to
maintain the security of the communication.

o In symmetric encipherment, an entity, say Alice, can send a message to other


entity, say Bob, over an insecure channel with the assumption that an adversary,
say Eve, cannot understand the contents of the message by simply eavesdropping
over the channel.
o Alice encrypts the message using an encryption algorithm. Bob decrypts the
message using a decryption algorithm.

o Encryption/decryption can be thought of as electronic locking system. In


symmetric-key enciphering, Alice puts the message in a box and locks the box
using the shared secret key; Bob unlocks the box with the same key and takes out
the messages.

o Mathematical notations:

Ciphertext:Y=E(K,X)

Plaintext:X=D(K,Y)

o Caesar cipher as a simple example of symmetric key encipherment. In a Caesar


cipher, each letter in the plaintext is shifted a certain number of places down the
alphabet.

o Encryption:

1.Choose a shift value, for example, 3.

2.Plaintext: HELLO

3.Shift each letter in the plaintext by the chosen value.

H+3=K

E+3=H

L+3=O

L+3=O

O+3=R

4.The encrypted ciphertext is "KHOOR."

o Decryption:

1. Use the same shift value, in this case, 3.


2. Ciphertext: KHOOR
3. Shift each letter in the ciphertext backward by the chosen value.

K-3=H
H-3=E

O-3=L
O-3=L
R-3=O

4. The decrypted plaintext is "HELLO."

 Asymmetric-key cryptography/public key cryptography[important]

Or
o Asymmetric-key cryptography, also known as public-key cryptography.

o It uses a pair of keys – a public key and a private key – to encrypt and
decrypt data.

o The public key is available to anyone , while the private key is kept secret
by the owner.

o To send a secure message to Bob, Alice firsts encrypts the message using
Bob’s public key. To decrypts the message, Bob uses his own private key.

o In asymmetric encryption, the sender uses the recipient’s public key to


encrypt the data. The recipient then uses their private key to decrypt the
data.

o Asymmetric encryption is commonly used in various applications,


including secure online communication, digital signatures, and secure
data transfer including email encryption, e-commerce, and online
banking.

o Examples of asymmetric encryption algorithms include RSA, Diffie-


Hellman.

o Mathematical notations:

o Anyone can encrypt a message using the public key, but only the holder
of the private key can unlock it.

o Example of Asymmetric Encryption


Email communication is one way to show asymmetric encryption in
action. Let’s say Alice and Bob have a public-private key pair and Alice
wishes to send Bob an encrypted message. Using Bob’s public key, Alice
encrypts her message before sending it to him. Bob uses his private key to
decrypt the message after receiving it encrypted.
ADVANTAGES OF BLOCKCHAIN TECHNOLOGY(CW)
extra

Transparency

Blockchain's decentralized nature gives all parties access to the same information, which can
reduce fraud and increase trust.

Scalability

A scalable blockchain can support more transactions per second, which means it can handle
more transactions for mass usage.

Immutability

Blockchain records are immutable, which means information can't be easily manipulated or
erased, which helps to maintain transaction security, transparency, and efficiency.

Traceability

Blockchain technology can help users outline, join, and track their data, which can help to
prevent errors.

Efficiency

Blockchain technology can make transactions faster and more reliable, lower processing and
storage costs therefore it improves the user experience.

Data integrity

Blockchain can help uphold the authenticity of products, which can strengthen consumer
trust.

Direct transactions

Blockchain allows participants to transact directly with each other without need of third
party, like a bank or notary.

Disadvantages Of Blockchain

Regulation issues:

Blockchain's decentralized nature can make it difficult for central governments to accept
Bitcoin and other cryptocurrencies.

Vulnerability to attacks:

Blockchain can be vulnerable to attacks and technical vulnerabilities.


Lack of tools for multi-party data control:

Blockchain may lack tools for multi-party data control.

High implementation cost.

Blockchain is costlier compared to a traditional database. Additionally, businesses need


proper planning and execution to integrate blockchain into their process.

Data modification.

Blockchain technology does not allow easy modification of data once recorded, and it
requires rewriting the codes in all of the blocks, which is time-consuming and expensive. The
downside of this feature is that it is hard to correct a mistake or make any necessary
adjustments.

Speed and performance. Blockchain is considerably slower than the traditional database
because blockchain technology carries out more operations. First, it performs signature
verification, which involves signing transactions cryptographically. Blockchain also relies on
a consensus mechanism to validate transactions. Some consensus mechanisms, such as proof
of work, have a low transaction throughput. Finally, there is redundancy, where the network
requires each node to play a crucial role in verifying and storing each transaction.

MYTHS ABOUT BITCOIN

Myth #1: Bitcoin is a bubble


Bitcoin has gone through multiple price cycles over 12 years and at each time it has achieved
high crossover.
Think of Bitcoin like a rollercoaster ride. Sometimes it zooms up really high, and then
suddenly drops down. But each time it drops, it eventually climbs back up even higher.
Example: Just like how some big companies started small and went through ups and downs
before becoming super successful, Bitcoin has had its share of ups and downs too. So, while
it might seem like a bubble ready to burst, history shows that it has bounced back stronger
each time.

Myth #2: Bitcoin has no real-world uses


In recent years, Bitcoin has become increasingly popular as an inflation-resistant store of
value much like gold.
Think of Bitcoin as a new kind of gold but on the internet-it is called as digital gold. Just like
people trust gold to hold its value over time, they're starting to trust Bitcoin for the same
reason. And some really big companies, like Tesla and Square, are buying tons of Bitcoin
because they believe it's a smart move to protect their money from losing value. It's like
they're putting their money in a digital piggy bank they think will keep growing.

Myth #3: Bitcoin doesn’t have real value


Imagine you have a special kind of treasure chest that can only hold 21 million coins. Once
it's full, that's it—no more coins can be added. Now, imagine there are people called miners
who work to find these coins and put them in the chest. But here's the trick: every once in a
while, the treasure chest magically makes it harder for miners to find coins. It's like the
treasure chest is saying, "Okay, we're slowing down now."
It's like if you had a rare toy that everyone wanted, and there were only a few left in the world
—the price would keep going up because everyone wants one but there aren't many available.
So, Bitcoin's value comes from its limited supply (only 21 million coins) and the fact that it
becomes harder to get new coins over time. This scarcity, along with people wanting Bitcoin
more and more, makes its value real.
Myth #4: Bitcoin will just be replaced by a competitor
Though thousands of rival cryptocurrencies have been created over the past decade,
Bitcoin has maintained its position as the most valuable and popular cryptocurrency,
comprising around 60% of the market. This dominance is attributed to Bitcoin's "first-mover"
advantage and its commitment to decentralization and openness. While competitors exist,
Bitcoin's established status and widespread acceptance make it unlikely to be easily replaced.
Myth #5: Investing in Bitcoin is gambling
Investing in Bitcoin isn't inherently gambling but depends on factors like personal
circumstances, risk tolerance, and investment horizon. While Bitcoin has shown upward
trends over the past decade, it's also experienced significant downturns. It's essential for
investors to exercise caution, especially in volatile markets, and consider seeking guidance
from financial advisors before making significant investments.
Myth #6: Bitcoin isn’t secure
The Bitcoin network has never been hacked. Its open-source code has been examine carefully
by countless security experts and computer scientists.Bitcoin was also the first digital
currency to solve the double-spend problem, making “trustless” peer-to-peer currencies a
reality.
Further, All Bitcoin transactions are irreversible. Bitcoin’s core protocol has functioned
securely with 99.9% uptime since its creation in 2009.
A vast amount of computing power secures the network. And the miners that power the
network are distributed throughout the world, with nodes in 100 countries — which means
there are no single points of failure.
Myth #7: Bitcoin is bad for the environment
In fact bitcoin mining consumes a significant amount of energy, but assessing its precise
environmental impact is complex. It's important to consider that all digital activities,
including traditional banking systems, also require energy for operation. Comparing the
energy usage of Bitcoin mining to the global banking system can provide context for
understanding its environmental footprint.
Cryptographic Principles

Cryptographic principles are the fundamental concepts and techniques that


are used in the field of cryptography to secure communication and protect
data. These principles include confidentiality, integrity, authentication, non-
repudiation, and key management.

There are several fundamental principles that are important in the field of
cryptography, including −

 Confidentiality − Confidentiality refers to the ability to keep information private and


secure. Cryptographic techniques, such as encryption, can be used to protect the
confidentiality of information by making it unreadable to anyone who does not have the
proper decryption key.
 Integrity − Integrity refers to the ability to ensure that information has not been altered or
tampered with. Cryptographic techniques, such as hash functions, can be used to ensure
the integrity of information by providing a way to detect any changes to the data.
 Authentication − Authentication refers to the process of verifying the identity of a user
or device. Cryptographic techniques, such as digital signatures, can be used to
authenticate the identity of a user or device in a secure manner.
 Non-repudiation − Non-repudiation refers to the ability to prevent someone from
denying that they performed a particular action. Cryptographic techniques, such as digital
signatures, can be used to provide non-repudiation by allowing the sender of a message to
prove that they sent the message and the receiver to prove that they received the message.
 Key management − Key management refers to the process of generating, distributing,
and managing cryptographic keys. Proper key management is essential for the security of
a cryptographic system, as the security of the system depends on the secrecy of the key.

How can I keep my Bitcoins secure?


1: Use strong passwords.
Create complex and unique passwords for all your Bitcoin-related accounts and wallets. Strong
passwords typically combine upper and lower case letters, numbers, and special characters.
Avoid using easily guessable information like birthdays or common words.

2: Use 2 Factor Authentication for online services.


Enable 2FA on all your online services related to Bitcoin, such as exchanges and wallet services.
This adds an extra layer of security by requiring a second form of verification, typically a code
sent to your mobile device, in addition to your password.

3: Always encrypt your wallet files.


Encrypt your Bitcoin wallet files with a strong passphrase. This ensures that even if someone
gains access to your files, they cannot use your Bitcoins without decrypting the files first. Most
wallet software includes built-in encryption options.

4: Keep your paper wallets in a safe and secure place.


If you use paper wallets (physical printouts of your private keys and public addresses), store
them in a secure location such as a safe or a secure deposit box. Ensure they are protected from
physical damage, theft, and unauthorized access.

5: ALWAYS run antivirus software if you are on Windows.


If you are using a Windows computer, ensure you have reputable antivirus software installed
and running. This helps protect your system from malware, viruses, and other threats that could
compromise your Bitcoin wallet and private keys.

GENESIS BLOCK

 The first block in the chain is called the Genesis block.( Or )


 A Genesis Block is the first block in a cryptocurrency blockchain.
 A blockchain consists of a series of Block contains information about the Sender,
Receiver, number of bitcoins to be transferred.
 Each block contains a unique header and is individually identified by its block
header hash.
 Each new block in the chain is linked to the previous block.

 Example

Understanding the Genesis Block


 Blocks are effectively digital containers where data pertaining to the transactions on a
network are permanently recorded.
 A block records as many of the most recent Bitcoin transactions it can hold that have
not yet entered any previous blocks.
 Thus, a block is like a ledger or a record book page. Each time a block is "completed,"
it gives way to the next block in the blockchain.
 A closed block is thus a permanent store of records that, once confirmed, cannot be
altered or removed.
The Genesis Block, also known as Block 0, is the very first block upon which additional
blocks in a blockchain are added.
Blocks store primary information about transactions, such as date, time, and purchase amount
of your last transaction
Each Block has

 Data

 Hash

 Hash of the previous block


(To this question u can also write creation of block)-3rd module

MODULE-2
Blockchain Architecture

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.

1. 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.

2. Previous Block Address/ Hash: It is used to connect the i+1th block to the i th block
using the hash. It is a reference to the hash of the previous (parent) block in the chain.

3. Timestamp: It is a system that verify the data in 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.

4. Nonce: A nonce number is used 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 will mine, test, and eliminate many Nonce per second until they find that
Valuable Nonce is valid.
5. 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.

Key Characteristics of Blockchain Architecture

Decentralization: In centralized transaction systems, each transaction needs to be validated


in the central trusted agency (e.g., the central bank). In contrast to the centralized mode, a
third party is not needed in the blockchain. Consensus algorithms in blockchain are used to
maintain data stability in a decentralized network.
Persistency: Transactions can be validated quickly and invalided transactions would not be
admitted by persons or miners who mining the crypto . It is not possible to delete or roll
back transactions once they are included in the blockchain network. Invalid transactions do
not carry forward in the blockchain.
Anonymity: Each user can interact with the blockchain with a generated address , which
does not disclose the real identity
of the miner.
Auditability: Blockchain stores data of users based on the Unspent Transaction Output
(UTXO)model.
Every transaction has to refer to some previous unused transactions . Once the current
transaction is recorded into the
blockchain, the position of those referred unused transactions switches from unused to
used. Due to this process, the transactions can be easily tracked and not harmed between
transactions.
Transparency: The transparency of blockchain is like cryptocurrency, in bitcoin every
transaction is done by the address . And for security, it hides the person’s identity between
and after the transaction . All the transactions are made by the owner of the block associated
with the address, this process is transparent and there is no loss for anyone who is involved
in this transaction.
Cryptography: The blockchain concept is fully based on security and for that, all the
blocks on the blockchain network want to be secure . And for security, it implements
cryptography and secures the data using the cipher text and ciphers .

Benefits of Blockchain:
 It is safer than any other technology.
 To avoid possible legal issues, a trusted third party has to supervise the transactions
and validate the transactions.
 There’s no one central point of attack.
 Data cannot be changed or manipulated, it’s immutable.

Versions of Blockchain
There are Three Version’s of BlockChain
 BlockChain 1.0 (Cryptocurrency) –
BlockChain Version 1.0 was introduced in 2005 by Hall Finley .
o Hall Finley implemented DLT (Distributed Ledger Technology ). This
represents first application based on Crypto currency.
o This allows Financial Transaction based on BlockChain technology or DTL
which is executed with the help of BitCoin.
o This type of Version is permissionless as any participant will perform valid
transaction of Bitcoin.
o This type(version) is mainly used in Currency and Payments.
o Blockchain 1.0 or Blockchain Version 1.0 aimed to introduce a transparent,
publicly accessible, completely decentralised, immutable ledger and
distributed system of transactions in the global financial market.
o Blockchain 1.0 is developed over the idea and structure of Bitcoin.
o It primarily focused on the development and creation of new
cryptocurrencies.
o Blockchain 1.0 is often termed a digital, decentralised, distributed ledger that
records transactions in a database shared by all nodes, updated by blockchain
miners and maintained and monitored by everyone with no individual
ownership.
 BlockChain 2.0 ( Smart Contracts) –
o The new Version of BlockChain come because there is a problem in version
1.0.
o In version 1.0 mining of bitcoin was wasteful and there was also lack
of Scalability of Network in it.
o So problem is improved in Version 2.0. In this version, the BlockChain is not
just limited to Cryptocurrencies but it will extend up to Smart Contracts.
o Small Contracts are Small Computer’s which live in the Chains of Blocks.
o These Small Computer’s are free computer programs that executed
automatically, and check the condition defined earlier like facilitation,
verification or enforcement and reduce transactions cost efficiency.
o In BlockChain 2.0, BitCoin is replaced with Ethereum. Thus, BlockChain 2.0
was successfully processing high number of Transactions on Public network
rapidly.
 BlockChain 3.0 (DApps) –
o After Version 2.0, new version was introduced which includes DApps which
is known as Decentralized Apps.
o A DApp is like a conventional app, it can have frontend written in any
language that makes calls to its backend, and its backend code is running on
decentralized Peer-To-Peer Network.
o It makes use of decentralized storage and communication which can be
Ethereum Swarm etc.
o DApps is decentralised, i.e. no single owner/authority that ensures
transparency, improved security, data accessible to all, no censorship and
flexible development.
o DApps brings many benefits such as zero downtime, ensuring privacy, data
integrity and trustless yet secure communication (business, transaction, etc.).
o There are many decentralized Applications like BitMessage, BitTorrent, Tor,
Popcorn, etc.
Advantages :
 Transaction takes place without requiring and Third Party Intermediary which ensures
the security of Details and Data.
 BlockChain use Cryptography in order to make sure the information is locked inside
the BlockChain.
 BlockChain removes Double records which accelerates Transactions.
Disadvantages :
 There is always risk of Error as long as human factor is evolved.
 Transaction cost of BitCoin is quite Higher.
 Blockchain technology is immutable it means we cannot make any changes when data
or information is inserted.

DIFFERENT TYPES/VARIANTS OF BLOCKCHAIN


 Public Blockchain.
 Private Blockchain.
 Hybrid Blockchain.
 Consortium Blockchain.

Permissionless Blockchain
It is also known as trustless or public blockchains, these are available to everyone to
participate in the blockchains process that used to validate transactions and data. These are
used in the network where high transparency is required.
Characteristics:
 Permissionless blockchain has no central authority.
 The platform is completely open-source.
 Full transparency of the transaction.
 Heavy use of tokens.
Permissioned Blockchain
These are the closed network only a set of groups are allowed to validate transactions or data
in a given blockchain network. These are used in the network where high privacy and
security are required.
Characteristics:
o A major feature is a transparency based on the objective of the organization.
o Another feature is the lack of anatomy as only a limited number of users are allowed.
o It does not have a central authority.
o Developed by private authority.
1. Public Blockchain
o These blockchains are completely open to following the idea of decentralization. They
don’t have any restrictions, anyone having a computer and internet can participate in
the network.
o As the name is public this blockchain is open to the public, which means it is not
owned by anyone.
o Anyone having internet and a computer with good hardware can participate in this
public blockchain.
o All the computer in the network hold the copy of other nodes or block present in the
network
o All nodes have equal access rights, which allows them to participate fully in creating
and validating blocks.
o A public blockchain often has an open source code, which means anyone can check
transactions to uncover problems and suggest possible fixes.
o Public blockchains are mainly used for cryptocurrency mining and exchange.
o These technologies use a proof-of-work or proof-of-stake consensus mechanism to
secure transactions.
Advantages:
 Trustable: There are algorithms to detect no fraud. Participants need not worry about
the other nodes in the network
 Secure: This blockchain is large in size as it is open to the public. In a large size,
there is greater distribution of records
 Anonymous Nature: It is a secure platform to make your transaction properly at the
same time, you are not required to reveal your name and identity in order to
participate.
 Decentralized: There is no single platform that maintains the network, instead every
user has a copy of the ledger.
Disadvantages:
 Processing: The rate of the transaction process is very slow, due to its large size.
Verification of each node is a very time-consuming process.
 Energy Consumption: Proof of work is high energy-consuming. It requires good
computer hardware to participate in the network
 Acceptance: No central authority is there so governments are facing the issue to
implement the technology faster.
Use Cases: Public Blockchain is secured with proof of work or proof of stake they can be
used to displace traditional financial systems. The more advanced side of this blockchain
is the smart contract that enabled this blockchain to support decentralization. Examples of
public blockchain are Bitcoin, Ethereum.

2. Private Blockchain

o A private blockchain is a type of blockchain network operated in a restricted


environment and controlled by a single entity.

o Although the distributed network is still powered by a peer-to-peer connection, the


blockchain ledger is only opened to a few predetermined nodes and not to the general
public.

o In a restricted network like this, only network nodes approved by the controlling
entity of the blockchain get to participate and contribute to the computing power of a
private blockchain.

o In addition, the participating nodes do not have equal rights to execute functions on
the network.

o Private blockchains also tend to be closed-source, which means the general public
does not have access to the code that powers the blockchain network, limiting the
chances of data tampering and other related issues.

o private blockchain networks are effective for securing


information. Therefore, companies that want to leverage the
advanced security and access controls that blockchain
technology offers without exposing their information to the
public eye tend to go for private blockchain.
o These companies use the private blockchain system for
various purposes like internal auditing, asset management,
internal voting, and so on. Examples of private blockchains
include Corda and Hyperledger.

Advantages:

 Speed: The rate of the transaction is high, due to its small size. Verification of each
node is less time-consuming.
 Scalability: We can modify the scalability. The size of the network can be decided
manually.
 Privacy: It has increased the level of privacy for confidentiality reasons as the
businesses required.
 Balanced: It is more balanced as only some user has the access to the transaction
which improves the performance of the network.

Disadvantages:

 Security- The number of nodes in this type is limited so chances of manipulation are
there. These blockchains are more vulnerable.
 Centralized- Trust building is one of the main disadvantages due to its central nature.
Organizations can use this for malpractices.
 Count- Since there are few nodes if nodes go offline the entire system of blockchain
can be endangered.

Use Cases: With proper security and maintenance, this blockchain is a great asset to
secure information without exposing it to the public eye. Therefore companies use them
for internal auditing, voting, and asset management. An example of private blockchains is
Hyperledger, Corda.

3. Hybrid Blockchain

o A hybrid blockchain combines elements of both public and private blockchain


systems.

o It is managed by a central entity, with a private and public permission based


system.

o This will restrict access and while giving central authority only the specific data
will be opened to the general public.

o A hybrid blockchain system is private in the sense that transactions and records
are not public.

o However, they can be verified by approved users through a smart contract system
when necessary. Also, the private entity that controls a hybrid blockchain system
cannot alter or make any changes to transactions on the blockchain.
o Companies operating in highly regulated industries like the banking sector often
prefer this type of system.

o It is also used in industries with systems that serve a large section of the public
where transparency is important, but access has to be regulated, such as real
estate, retail, and the healthcare industry.

Advantages:

 Ecosystem: Most advantageous thing about this blockchain is its hybrid nature. It
cannot be hacked as 51% of users don’t have access to the network
 Cost: Transactions are cheap as only a few nodes verify the transaction. All the nodes
don’t carry the verification hence less computational cost.
 Architecture: It is highly customizable and still maintains integrity, security, and
transparency.
 Operations: It can choose the participants in the blockchain and decide which
transaction can be made public.

Disadvantages:

 Efficiency: Not everyone is in the position to implement a hybrid Blockchain. The


organization also faces some difficulty in terms of efficiency in maintenance.
 Transparency: There is a possibility that someone can hide information from the
user. If someone wants to get access through a hybrid blockchain it depends on the
organization whether they will give or not.
 Ecosystem: Due to its closed ecosystem this blockchain lacks the incentives for
network participation.

Use Case: It provides a greater solution to the health care industry, government, real
estate, and financial companies. It provides a remedy where data is to be accessed
publicly but needs to be shielded privately. Examples of Hybrid Blockchain are
Ripple network and XRP token.

4. Consortium Blockchain

o It is also known as a federated blockchain. a consortium blockchain is managed by


multiple entities instead of just one.

o In this case, the organizational members that form the consortium, collaborate to
manage the decentralized blockchain.

o The consortium blockchain system eliminates the problems associated with


having just one controlling entity for the network like in private blockchains

o A consortium blockchain is governed by consensus mechanisms controlled by


preset centralized nodes. The validator node in a consortium blockchain initiates,
receives, and validates transactions on the blockchain network.
o This system of managing blockchain transactions is commonly used by banks and
other players in the financial services industry. Multiple banks can come together
to form a consortium blockchain, with the participating parties deciding which
nodes validate transactions. It may also be used by supply chains and research
organizations.

Advantages:
 Speed: A limited number of users make verification fast. The high speed makes this
more usable for organizations.
 Authority: Multiple organizations can take part and make it decentralized at every
level. Decentralized authority, makes it more secure.
 Privacy: The information of the checked blocks is unknown to the public view. but
any member belonging to the blockchain can access it.
 Flexible: There is much divergence in the flexibility of the blockchain. Since it is not
a very large decision can be taken faster.
Disadvantages:
 Approval: All the members approve the protocol making it less flexible. Since one or
more organizations are involved there can be differences in the vision of interest.
 Transparency: It can be hacked if the organization becomes corrupt. Organizations
may hide information from the users.
 Vulnerability: If few nodes are getting compromised there is a greater chance of
vulnerability in this blockchain
Use Cases: It has high potential in businesses, banks, and other payment processors. Food
tracking of the organizations frequently collaborates with their sectors making it a
federated solution ideal for their use. Examples of consortium Blockchain are Tendermint
and Multichain.

BLOCKCHAIN VS SHARED DATABASE

How blockchain architecture differs from RDBMS


For this u can write either the difference with diagram or below content
Blockchain Architecture

1. Decentralization: Blockchain operates on a decentralized network where each node has a


copy of the entire blockchain. There is no central authority, and data integrity is maintained
through consensus mechanisms(pow,pos).
2. Data Structure: Blockchain uses a sequential chain of blocks, each contains a list of
transactions. Each block is linked to the previous one through a cryptographic hash which
forms a secure and immutable chain.
3. Immutability: Once data is written to the blockchain, it cannot be altered or deleted. This
immutability ensures data integrity and trust among participants.
4. Consensus Mechanisms: Blockchain relies on consensus algorithms like Proof of Work (PoW)
or Proof of Stake (PoS) to validate and add new transactions to the ledger. This ensures that
all nodes agree on the state of the blockchain.
5. Transparency and Security: All transactions are transparent and can be publicly verified, by
enhancing security and trust. Cryptographic techniques ensure that data is tamper-proof.

Relational Database Management System (RDBMS)

1. Centralization: RDBMS typically operates on a centralized server controlled by a single


authority. The database administrator has full control over the database.
2. Data Structure: RDBMS uses tables to store data in rows and columns. These tables are
related through foreign keys and can be queried using Structured Query Language (SQL).
3. Flexibility: Data in RDBMS can be updated, deleted, and modified easily. Transactions are
managed through ACID (Atomicity, Consistency, Isolation, Durability) properties to ensure
data reliability.
4. Transaction Management: RDBMS handles transactions using SQL-based operations,
ensuring that data remains consistent and reliable through the use of locks and concurrency
controls.
5. Privacy and Control: Data in an RDBMS is typically private and accessible only to authorized
users. Security is maintained through access control mechanisms and database management
policies.
6.

OR
OR
The main difference between a blockchain and a shared database is centralization:
 Blockchain
A decentralized network that stores data using the unused hard disk space of users around
the world. Each participant has a secure copy of all records and changes, which allows
users to view the data provenance. Blockchain technology can also immediately identify
and correct unreliable information.
 Shared database
A central resource that consolidates files and other information for multiple users and
data systems to access or share simultaneously. Shared storage can simplify information
security, streamline backup and archive processes, and store data in a single resource.

INTRODUCTION TO CRYPTOCURRENCIES
Cryptocurrency received its name because it uses encryption to verify transactions. This
means advanced coding is involved in storing and transmitting cryptocurrency data
between wallets and to public ledgers. The aim of encryption is to provide security and
safety.
The first cryptocurrency was Bitcoin, which was founded in 2009 and remains the best
known today.
Definition
Cryptocurrency is a digital payment system that doesn't rely on banks to verify
transactions. It’s a peer-to-peer system that can enable anyone anywhere to send and
receive payments. Instead of being physical money carried around and exchanged in the
real world, cryptocurrency payments exist purely as digital entries to an online database
When you transfer cryptocurrency funds, the transactions are recorded in a public ledger.
Cryptocurrency is stored in digital wallets.
How does cryptocurrency work?
Cryptocurrencies run on a distributed public ledger called blockchain, a record of all
transactions updated and held by currency holders.
Units of cryptocurrency are created through a process called mining, which involves
using computer power to solve complicated mathematical problems that generate coins.
Users can also buy the currencies from brokers, then store and spend them using
cryptographic wallets.
If you own cryptocurrency, you don’t own anything tangible. What you own is a key that
allows you to move a record or a unit of measure from one person to another without a
trusted third party.
Although Bitcoin has been around since 2009, cryptocurrencies and applications of
blockchain technology are still emerging in financial terms, and more uses are expected in
the future. Transactions including bonds, stocks, and other financial assets could
eventually be traded using the technology.

Cryptocurrency examples/TYPES OF CRYPTOCURRENCY


1. Bitcoin
Bitcoin is the first decentralized cryptocurrency using blockchain technology to facilitate
payments and digital transactions. Instead of using a central bank to control the
transaction Bitcoin's blockchain acts as a public ledger of all transactions in the history of
Bitcoin.
The ledger allows a party to prove they own the Bitcoin they're trying to use and can help
prevent fraud and other unapproved tampering with the currency. A decentralized
currency can also make peer-to-peer money transfers faster and less expensive than
traditional currency exchanges involving a third-party institution.

2. Ether (Ethereum)
Ether is the token used to facilitate transactions on the Ethereum network. Ethereum is a
platform that uses blockchain technology to enable the creation of smart contracts and
other decentralized applications.
3. Tether
Tether is a stablecoin, or a currency tied to a fiat currency -- in this case, the U.S. dollar.
The idea behind Tether is to combine the benefits of a cryptocurrency with the stability of
a currency issued by a sovereign government.
4. Binance Coin
Binance Coin is available on the Binance cryptocurrency exchange platform, along with
other digital coins that are available for trading. Binance Coin can be used as a type of
currency, but it also facilitates tokens that can be used to pay fees on the Binance
exchange and to power Binance's DEX (decentralized exchange) for building apps.
5. USD Coin

USD Coin is another stablecoin, and, like Tether, it is pegged to the U.S. dollar. Also like
Tether, USD Coin is hosted on the Ethereum blockchain. The idea behind USD Coin was
to create a "fully digital" dollar, one that has the stability of U.S. fiat currency but doesn't
require a bank account or that the holder live in a particular country. Rather than an
investment, USD Coin is envisioned as everyday money that can be spent with merchants
on the internet.
APPLICATIONS OF CRYPTOCURRENCY

1. Banking: For banks, blockchain makes it easier to trade currencies, secure loans
and process payments. This tech acts as a single-layer, source-of-truth that’s
designed to track every transaction ever made by its users. This immutability
protects against fraud in banking, leading to faster settlement times, and provides a
built-in monitor for money laundering. Banks also benefit from faster cross-border
transactions at reduced costs and high-security data encryption.

2. Smart Contracts: Smart contracts are self-executing protocols that automate


transaction verification. They’re coded into the blockchain and set by
predetermined terms. In addition to reducing human error, their function is to
facilitate decentralization and create a trustless environment by replacing third-party
intermediaries.
3. NFTs: Blockchain makes the creation, ownership and trading of NFTs, or non-
fungible tokens, possible. The reason why copying these digital assets is not as
simple as a quick screen capture is because each NFT is encrypted with blockchain
technology, which keeps a live running record of ownership over the piece. Smart
contracts govern transactions, assigning and reassigning ownership and delivering
royalties to artists as pieces move from wallet to wallet.

4. U can write applications of bitcoin also

How do u get bitcoins[5m]


We can get bitcoins in 4 ways
1. Mining

2. wiring in fiat currency to an BTC exchange

3. Buying from an individual

4. Selling items for BTC

1. Mining
Bitcoin mining involves using computer hardware to solve complex mathematical problems
that validate transactions on the Bitcoin network. Miners are rewarded with newly created
bitcoins and transaction fees.

 Set Up Hardware: Miners use specialized hardware known as ASICs (Application-


Specific Integrated Circuits) because they are much more efficient than general-
purpose computers.
 Join a Mining Pool: Individual mining can be very competitive, so many miners join
pools to combine their processing power and share rewards.
 Install Mining Software: Software connects miners to the Bitcoin network and the
mining pool.
 Solve Mathematical Problems: The hardware attempts to solve cryptographic
puzzles. The first miner to solve the puzzle adds a new block to the blockchain and
earns bitcoins.
 Earn Bitcoins: Successful miners receive a block reward (new bitcoins) and
transaction fees from the transactions included in the block.

2. Wiring in Fiat Currency to a BTC Exchange

Exchanges are platforms where you can buy and sell bitcoins using traditional currencies (fiat
money). Here's how it works:

 Choose an Exchange: Select a reputable Bitcoin exchange like Coinbase, Binance, or


Kraken.
 Create an Account: Register and verify your identity, often required to comply with
regulations.
 Deposit Fiat Currency: Transfer money from your bank account or use other
methods like credit/debit cards to deposit funds into your exchange account.
 Buy Bitcoin: Use the deposited fiat currency to purchase bitcoins. You can usually
buy at the current market price or set a limit order.

3. Buying from an Individual

You can also buy bitcoins directly from another person. This can be done through various
methods:

 In-Person Transactions: Meet the seller in person and exchange cash for bitcoins
using a mobile wallet app.
 Online Platforms: Use peer-to-peer platforms like LocalBitcoins or Paxful, which
connect buyers and sellers.
 Escrow Services: These platforms often offer escrow services to hold the bitcoin until
both parties confirm the transaction, ensuring safety.

4. Selling Items for BTC

Accepting Bitcoin as payment for goods or services is another way to acquire it. Here’s how:

 Online Business: Set up a website and use a payment processor like BitPay or
BTCPay Server to accept Bitcoin.
 Physical Business: Use a point-of-sale system or a simple QR code for Bitcoin
transactions in a brick-and-mortar store.
 Peer-to-Peer Sales: Sell items to individuals and request payment in Bitcoin. Use a
Bitcoin wallet to receive and store the bitcoins.

You might also like