Unit - I
Unit - I
Unit - I
What is blaockchain?
A Blockchain is “an open, distributed legder that can record transactions
betwwen two parties efficiency and in a verifiable and permanent way”.
The keywords:
o Open :accessible to all
o Distributed or Decentralized: no single party control
o eficient :fast and scalable,
o Verfiable :everyone can check the validity of informatio
o Permanent: the information is persistent.
Disadvantage:
The major disadvantage of this method is that both can’t simultaneously edit the
document.
Case:2 information sharing by using centralized database.
The shared Google docs or similar platforms, both Alice and Bob can write the
document simultaneously.
Blockchain Architecture:
The below picture represents the Blockchain Technology where multiple nodes
(Entities or Users or Computers or Network Applications) communicate without
depending on a centralized system.
Fig:
1. Every node maintains a local copy of the global datasheet
2. The system ensures consistency among the local copies
The local copies at every node are identical
The local copies are continuously updated based on the global
information
3. In general, it is named as a public ledger
A database of historical information available to everyone
The historical information may be utilized for future computation
Example from banking system:
The historical information is the banking transactions
The old transactions are used to validate the new transactions
Distributed ledger:
Distributed ledgers are the databases shared across a network and spread
over various geographical locations. A ledger is a collection of financial
accounts and, in such a case, distributed means spread out and controlled
globally.
Fig:
This transaction is not valid, and the participant will not accept it. Hence, it will
not be added into the public ledger as the record shows Alice is only having
50$.
WHAT IS BLOCKCHAIN TECHNOLOGY?
Structure of Blockhain:
Blockchain is a linear chain of blocks.
Each block contains a set of transactions and other essential details.
Blocks are linearly connected and cryptographically secured.
Genesis Block
Each block header contains the previous block hash, current block hash,
nonce, Merkle root, and other details.
All blocks are connected linearly by carrying the hash of the previous
block.
The previous block hash is used to compute the current block hash.
The first block with no previous block hash is called “Genesis Block.”
For adding a new block to the network, the blockchain follows consensus
mechanisms like proof of work (PoW), proof of stake (PoS), etc.
How does Blockchain Works?
The validating nodes will then pick up a set of transactions and add it to a
new block.
After encrypting and digitally signed, the block will have the hash of the
last block in the blockchain added in its header. This block will be
validated by validator nodes.
Once the validation is completed, the block is added to the blockchain and
transaction data is secured in the blockchain.
The End user of the blockchain network can initiate the transaction by
installing an application which could either be the light node or full node.
The Blockchain developer community is responsible for designing the
protocol and implementing it into software.
The running of Blockchain network is handled by full nodes and
Miner/Validator nodes.
Blockchain History
Fig :
1991
In 1991, two scientists, Stuart Haber and W. Scott Stornetta, published a chain
of blocks secured using cryptography, the content and its date couldn't be
tampered with. This system later became known as Blockchain Technology.
1992
Merkle Trees was included to make it more efficient. This made adding
multiple documents on one block in a Blockchain possible.
2000
2004
Hal Finney introduced a digital Cash system in the year 2004. This
system was referred to as a Reusable proof of work, and it solved the critical
issue of double spending.
2008
2009
• Satoshi Nakamoto released the white paper for bitcoin in the year 2009.
2010
Laszlo Hanycez completes the first ever purchase using Bitcoin — two Papa
John’s pizzas. Hanycez transferred 10,000 BTCs, worth about $60 at the time.
2011
2013
2014:
• In 2015, the concept of Smart contracts launched and turns out to be one
of the biggest applications of Blockchain.
2016
2017
2018
2019
• Face book showed interest in the block chain space and announced their
crypto currency named Libra.
• Later, Amazon Web Services (AWS) announced the Amazon Block chain
service on its cloud platform
2020
2021
• Tesla buys $1.5 billion in BTC, becoming the first car manufacturer to
accept Bitcoin as a form of automobile payment.
2022
Fig :
Blockchain 1.0
The Rise and Struggles of Blockchain as a Future Technology (2013 –
2018)
1.Bitcoin:
• Bitcoin is essentially an electronic cash transfer system that is automated
and functions without the need for human intervention between
transactions as a trusted authority.
Fig:
2. Dogecoin:
• It is considered an altcoin.
Fig:
3. Litecoin:
Fig:
4. Monero:(XMR)
Fig:
Blockchain 2.0
• The next development in blockchain technology expanded on the
capabilities of the blockchain protocols.
• Ethereum was the first blockchain with the smart contract integrated into
its protocol.
1. Smart contracts:
Blockchain 3.0
Blockchain 3.0 is the final developmental stage of blockchain technology.
Blockchain 3.0 has applications in a broader set of industries outside the
domain of finance and economics.
The major concerns for this generation of blockchains are sustainability,
scalability, cost-effectiveness, more decentralization, and improved
security
• Manufacturing.
What is Cryptography?
Cryptography uses mathematical techniques to transform data and prevent it from being read or
tampered with by unauthorized parties.
Ciphertext :
o Ciphertext is encrypted text transformed from plaintext using an encryption algorithm.
Encryption –
o A process of transforming Plain Text into Cipher Text is known as Encryption.
Decryption –
o A reverse process of encryption is known as Decryption. It is a procedure of transforming
Cipher Text into Plain Text.
Key :
o A key is a group of random characters in a particular order, known only to
sender/receiver
Working of Cryptography:
Types of Cryptography:
Symmetric Cryptograph or private key cryptography:
Asymmetric Cryptography or public key Cryptography:
Applications of Cryptography
Transaction through Digital Currency
Computer Passwords
Secure Web Browsing
Electronic Signature
Authentication
Cryptocurrency
Email Delivery
End to End encryption
Principles of cryptography:
Confidentiality:
o Confidentiality refers to the ability to keep information private and secure.
Integrity:
o Integrity ensures a message or transaction has not been tampered with .
Non-repudiation :
o Non-repudiation refers to the ability to prevent someone from denying that they
performed a particular action.
Authentication :
o Authentication refers to the process of verifying the identity of a user or device.
Currency:
Before we understand cryptocurrency, let’s first understand some basics about
currency that is being used in today’s world. It is also known as “Fiat Currency.”
Characteristics of Fiat Currency:
2. These are centrally controlled through various financial institutions like banks
and legal entities.
3. It is very Inflationary which means over a period of time, the value of the
currency decreases and inflation use in the intuition all together.
6. That is the reason why Law enforcement comes in picture to stop and to
prosecute those who involve into counterfeit Fiat currency.
There are various Security Features that are being implemented in Fiat
Currencies:These are very common across the globe like Watermark, Security
Thread, Images, Identification marks, fluroscent inks are being used in currency
notes.
Watermark
Security Thread
Cryptocurrency
A cryptocurrency is a digital currency, which is an alternative form of payment
created using encryption algorithms.
Types of cryptocurrency:
Working of cryptocurrency:
o Cryptocurrency transactions occur through electronic messages that are sent to the entire
network with instructions about the transaction.
o The instructions include information such as the electronic addresses of the parties
involved, the quantity of currency to be traded, and a time stamp.
o Suppose Alice wants to transfer one unit of cryptocurrency to Bob. Alice starts the
transaction by sending an electronic message with her instructions to the network, where
all users can see the message.
o The transaction sits with a group of other recent transactions waiting to be compiled into
a block (which is just a group of the most recent transactions).
o The information from the block is turned into a cryptographic code and miners compete
to solve the code to add the new block of transactions to the blockchain.
o Once a miner successfully solves the code, other users of the network check the solution
and reach an agreement that it is valid.
If you want to send someone money in the United States, there are few ways to move money
or assets from one account to another faster than you can with cryptocurrency.
2. Transaction costs
3. Accessibility
Anyone can use cryptocurrency. All you need is a computer or smartphone and an internet
connection. The process of setting up a cryptocurrency wallet is extremely fast compared to
opening an account at a traditional financial institution. There's no ID verification. There's no
background or credit check.
4. Security
Unless someone gains access to the private key for your crypto wallet, they cannot sign
transactions or access your funds.
5. Privacy
Transactions are pseudonymous, which means you have an identifier on the blockchain --
your wallet address -- but it doesn't include any specific information about you.
6. Transparency
All cryptocurrency transactions take place on the publicly distributed blockchain ledger.
There are tools that allow anyone to look up transaction data, including where, when, and
how much of a cryptocurrency someone sent from a wallet address.
Disadvantages:
1. Scalability
The number of users, transactions, and applications increases, the ability
of blockchain networks to process and validate them in a timely way becomes
strained.
2. Interoperability
Interoperability, or the ability of different blockchain networks to
communicate and interact with each other, is another crucial challenge facing the
industry.
3. Complexity
Blockchain is a complex technology that requires a high level of technical
expertise to implement and maintain.
4. Energy Consumption
The process of validating transactions on a blockchain network requires a lot of
computing power, which in turn requires a lot of energy.
Financial Services:
There are many financial services for buying, selling, exchange the bitcoin online.
Ripple:
Coinffeine:
Coinffeine will allow customers in over 70 countries to purchase and sell bitcoin.
Coinffeine has launched its decentralised open-sourced P2P bitcoin exchange in over 70
countries.
By integrating with Russia-based payment processor OKPay, the Spanish company
has enabled bitcoin enthusiasts to purchase and sell the digital currency in countries including
Russia, China, Indonesia, Brazil and the Eurozone.
Paypal
Crypto, short for cryptocurrency, is a digital currency you can buy, sell, and securely hold in
your PayPal account.
PayPal also supports the transfer of cryptocurrencies between PayPal, Venmo, and other
supported wallets and exchanges.
Kraken
BTCjam:
BTCjam was a peer-to-peer lending (aka "P2P lending") service where individuals
could borrow or lend using bitcoin.
Tera Exchange:
Vaurum:
Vaurum is building an API for financial institu‐ tions to offer traditional brokerage investors
and bank customers access to Bitcoin.
Buttercoin
Buttercoin, a Bitcoin trading platform and exchange for high-volume transactions (200,000–
500,000 Bitcoin, or $70–$175 million), targeted at a business clientele who has a need to
complete large-scale Bitcoin transactions
DTCC:
Depository Trust Company and the National Securities Clearing Corporation, or DTCC is
current stock trading market infrastructure that provides clearing, settlement, risk
management, central counterparty services and a guarantee of completion for certain
transactions.
Bitcoin Prediction Markets:
What is prediction:
A prediction is what someone thinks will happen. A prediction is a forecast, but not only
about the weather. Pre means “before” and diction has to do with talking. So a prediction is a
statement about the future. It's a guess, sometimes based on facts or evidence .
Crypto prediction markets allow users to earn money by predicting random crypto-related
events.
One example of new tech with old tech is Bitcoin prediction markets like Predictious and
Fairlay.
Predictious:
Predictious is an online Bitcoin prediction marketplace. Users can trade predictions on Sport, Movies,
TV, Politics, Bitcoin Economy, etc. and if they are correct, they can win Bitcoins. Members can use
the Predictious' API to create custom applications and prediction market bets are futures contracts.
Fairlay:
Fairlay is a beta website which seeks to predict the bitcoin market and gain foreknowledge of its ups and
downs.
Centralized Vs Decentralized
Centralized:
A centralized database is a collection of data that is stored, located, and maintained in a single location.
This kind of database is modified and managed from that single location only. For instance, a desktop or
server CPU or a mainframe computer can be called a centralized database system.
Disadvantages:
Decentralized:
Advantages:
Decentralized — A decentralized framework using blockchain eliminates a
single point of failure.
Distributed — Data is distributed across several nodes. This ensures that
data can always be accessed even if one or more nodes are down.
Security — A decentralized database uses cryptographic techniques to
ensure full privacy and security of information.
Scalability — The central server resources are finite in centralized systems.
If the number of clients increases, the server load may increase and cannot
perform well. In the case of decentralized databases, the capacity increases,
and more users can access the data at the same time.
Immutability — The data once stored on the blockchain cannot be altered
or manipulated. This ensures that data is resilient thereby giving more
accountability to information.
Characteristics of Blockchain
Didtributed:
Highly Available:
Immutable:
Transparent:
Auditable:
Secure:
Supporting privacy:
Distributed trust:
Blockchain is a complex technology, but it is very simple - distributed trust. This means you
can trust the network, without trusting anyone - or anything on the network.
The following features make the blockchain network is a distributed trusted network.
Peer-to-peer network
Immutable
Transparency
Auditable
Distributed ledger
No third party
Peer-to-per network:
Blockchain is decentralized and peer-to-peer networking system so it enables direct peer-to-
peer transactions.
Immutable:
Once data stored on blockchain database that we cannot altered and tempered.
Transparency:
All transactions are recorded on distributed ledger and every participant have one copy of
ledger is mechanism encourage the transparency on the network.
Auditable:
Blockchain records the entire journeys of transaction from starting to end these are called
logs. These logs are available at every node for auditing.
Distributed ledger:
Blockchain database is also called the distributed ledger because every node has copy of
database.
No third party:
There is no third party as intermediate for verifications of transaction. We can directly
transfer the amount one account to another.
Advantage using blockchain :
1. It provides greater trust among users.
2. It provides greater security among data.
3. Reduce the cost of production.
4. Improve Speed.
5. Invocation and tokenization.
6. It provides immutable records.
7. Smart contracts
Disadvantages using blockchain :
1. Data modification is not possible.
2. It requires large storage for a large database.
3. The owner cannot access the private key again if they forget or lose it.