Unit 1-Introduction To Blockchain
Unit 1-Introduction To Blockchain
INTRODUCTION TO BLOCKCHAIN
Block
1. Data :“hello everyone”
2.Prev Hash:23432FRT123
3. Hash :123FFRE342
Blockchain
1
SITB3011 BLOCK CHAIN – UNIT 1
➢ Every new record is validated across the distributed network before it is stored in a
block.
➢ All information once stored on the ledger is verifiable and auditable but not editable
.
“To access data of the first ever created block ,you have to traverse from the last created
block to the first block”
How trading happens Using Current System
❑ Financial exchanges are slow. Checking and low cost wire services take days to
complete
2
SITB3011 BLOCK CHAIN – UNIT 1
❑ Also, central authority in control can overuse the power and can create money as per
their own will
3
SITB3011 BLOCK CHAIN – UNIT 1
4
SITB3011 BLOCK CHAIN – UNIT 1
Decentralized Applications
• The code runs on a peer-to-peer network of nodes and no single node has control
over the dApp.
• Depending on the functionality of the dApp, different data structures can be used to
store the application data.
5
SITB3011 BLOCK CHAIN – UNIT 1
Distributed Applications
• CDN
• AWS
• Cloud Instances
6
SITB3011 BLOCK CHAIN – UNIT 1
• A System where two or more nodes work with each other in a coordinated fashion
in order to achieve a common outcome
• It’s modeled in such a way that end users see it as a single logical platform.
What is a node ?
• A node can be defined as an individual processing unit in a distributed system
• All nodes are capable of sending and receiving messages to and from each other.
Introduction – Blockchain
Blockchain technology is a distributed ledger technology originally proposed for the
crypto-currency Bitcoin.
FEATURES
– Immutable and tamper-proof data store
What is Blockchain?
A blockchain is a decentralized, distributed public ledger where all transactions are
verified and recorded.
Blockchain is a system comprised of.
Transactions
Immutable ledgers
Decentralized peers
Encryption processes
Consensus mechanisms
Optional Smart Contracts
Transactions
As with enterprise transactions today, Blockchain is a historical archive of decisions and
actions taken
Proof of history, provides provenance
7
SITB3011 BLOCK CHAIN – UNIT 1
Immutable
As with existing databases, Blockchain retains data via transactions.
The difference is that once written to the chain, the blocks can be changed, but it is extremely
difficult to do so. Requiring rework on all subsequent blocks and consensus of each.
The transaction is, immutable, or indelible
In DBA terms, Blockchains are Write and Read only
Like a ledger written in ink, an error would be resolved with another entry.
Decentralized Peers
Rather than the centralized “Hub and Spoke” type of network, Blockchain is a
decentralized peer to peer network. Where each NODE has a copy of the ledger.
Legacy Network Blockchain Network Centralized DB Distributed
Ledgers
8
SITB3011 BLOCK CHAIN – UNIT 1
9
SITB3011 BLOCK CHAIN – UNIT 1
10
SITB3011 BLOCK CHAIN – UNIT 1
• Decentralization: Both network information and the rules for how the network
operates are maintained by nodes due to consensus mechanism.
11
SITB3011 BLOCK CHAIN – UNIT 1
Benefit of blockchain
Unstoppable: Once the conditions programmed into a blockchain protocol are met,
an initiated transaction cannot be undone, changed, or stopped. It’s going to execute
and nothing – no bank, government, or third party – can stop it.
12
SITB3011 BLOCK CHAIN – UNIT 1
Lower Cost: In the traditional finance system, you pay third parties like banks to
process transactions. The blockchain eliminates these intermediaries and reduces
fees, with some systems returning fees to miners and stakes.
Peer-to-Peer: Cryptocurrencies like Bitcoin, let you send money directly to anyone,
anywhere in the world, without an intermediary like a bank charging transaction or
handling fees.
Universal Banking: anyone can access the blockchain to store money, it’s a great way to
protect against theft that can happen due to holding cash in physical locations.
Use cases
• Dubai has been able to integrate blockchain into eight industry sectors
• Real estate
• Tourism
• Security
• Transportation
• Finance
• Health
• Education.
Cryptocurrency
• Cryptocurrency can be used to pay for purchases online without going through an
intermediary, such as a bank, or it can be held as an investment.
13
SITB3011 BLOCK CHAIN – UNIT 1
• You can buy cryptocurrencies through crypto exchanges, such as Coinbase, Kraken
or Gemini. In addition, some brokerages, such as WeBull and Robinhood, also allow
consumers to buy cryptocurrencies.
Example Cryptocurrencies
Blockchain Evolution
14
SITB3011 BLOCK CHAIN – UNIT 1
Shared Ledger
15
SITB3011 BLOCK CHAIN – UNIT 1
Work
• Distributed ledgers are held, reorganized, and controlled by individuals called nodes.
16
SITB3011 BLOCK CHAIN – UNIT 1
• Afterward, the nodes update the versions of the database so that all the devices or
nodes will be of the same version.
• When a miner successfully puts a new transaction into a block, they receive a reward.
• It is the responsibility of miners to compute the cryptographic hash for new blocks.
• Whoever, among the miners, successfully finds the hash first, gets the reward.
• Miners dedicating more computational power to find the hash will be more
successful.
• Inherently decentralized
• Highly transparent
17
SITB3011 BLOCK CHAIN – UNIT 1
● The distributed ledger is spread along with the nodes so making it vulnerable to
attack.
● The transaction speed is low because of the operation of a large number of nodes.
2. Private Blockchains
3. Consortiums Blockchains
4. Hybrid Blockchains
Public Blockchains
• Anyone who has access to the internet can sign in on a blockchain platform to
become an authorized node and be a part of the blockchain network.
18
SITB3011 BLOCK CHAIN – UNIT 1
Disadvantages
Private Blockchains
• A Private Blockchain is just like a relational database i.e. fully centralized and owned
by a single organization.
• People who want to join require permission from the system administrator.
19
SITB3011 BLOCK CHAIN – UNIT 1
Consortiums blockchain
• greater privacy since the information from verified blocks is not exposed to the
public.
• Increased scalability - Bitcoin’s block transmits only up to 1 Mb* (from 1500 to 2700
transactions) per 10 minutes, when a consortium blockchain can optimize it to 1000
and more transactions per second.
Hybrid Blockchain
20
SITB3011 BLOCK CHAIN – UNIT 1
Advantages
Disadvantages
21
SITB3011 BLOCK CHAIN – UNIT 1
Bitcoin, Litecoin,
Example Ripple, Corda Hyperledger
Ethereum
Transactional
Costly Not so costly Not so costly
Cost
Carries basic
property of Yes Yes Yes
blockchain
22
SITB3011 BLOCK CHAIN – UNIT 1
• It is a challenge to keep all of these three components in balance. Usually, one of them
is partly sacrificed to get the other two.
• Scalability
• Security
• security, scalability, and decentralization. These are among the most prominent
driving factors in ongoing development (privacy/anonymity is another contender).
Security:
• Security is the most crucial concept, and without it, the technology would be unusable.
• Security is the most important of them all, as no one would use banks or Bitcoin without
it. For example, we could say the lack of security in has stopped us in adopting that
scalability solution.
Scalability:
• The technology must be able to grow to and handle a commercially viable scale. •
Decentralization:
23
SITB3011 BLOCK CHAIN – UNIT 1
24
SITB3011 BLOCK CHAIN – UNIT 1
Blockchain Government
Use Cases e-Estonia digital
ID, e-tax, i-voting Georgia –
Land Registry
25
SITB3011 BLOCK CHAIN – UNIT 1
1.7 Bitcoin
• Released in 2008 by Satoshi Nakamoto.
Bitcoin vs.
bitcoins
Bitcoin is
the system
bitcoins are
the units
What is Bitcoin?
26
SITB3011 BLOCK CHAIN – UNIT 1
Before Bitcoin
• Motivation
• Transaction costs
• Primary concerns
• Transaction security
• Double spends
• The system forces participants to trust financial institutions that are not always
trustworthy.
Transaction security
• Source is legitimate
27
SITB3011 BLOCK CHAIN – UNIT 1
• If the money is just digital codes, why not copy and paste to make more money?
• Timestamps
• Hashes
• Block chain
• Timestamp
• Each transaction is packaged and publicly recorded in the order it was carried out.
• Hash
Bitcoin
• Bitcoin is the official first cryptocurrency that had been released in 2009. It is
basically a digital currency and only exists electronically.
• Bitcoin is the first successful electronic cash system and coincidentally, the first
instance of a successful Blockchain.
• Each node stores the history of the chain of blocks, containing validated transactions
28
SITB3011 BLOCK CHAIN – UNIT 1
• Unlike previous P2P network models, members of the Bitcoin network are
incentivized to participate through cryptocurrency.
• Specifically, the incentive is for the people who mint (create) Bitcoin, called miners.
Bitcoin Properties
Mining bitcoins
• Until there are 21 million bitcoins, miners are paid for finding a hash in new coin.
• After 21 million, miners will charge transaction fees for creating a new block.
• The amount paid per hash goes down by half about every 4 years.
29
SITB3011 BLOCK CHAIN – UNIT 1
Owning bitcoins
• Users create accounts called wallets.
• Wallets are secured using passwords and contain the private keys used for
transferring bitcoins.
Wallets
Hardware wallets
• Hardware wallets are hardware devices that individually handle public addresses and
keys.
30
SITB3011 BLOCK CHAIN – UNIT 1
• when you open a wallet (in the hardware wallet or software wallet) you are provided
with 2 pair of keys (sometimes more).
• public key is used to generate the public cryptocurrency address you can use to
receive the cryptocurrency,
• the private key is used to sign the transactions confirming your ownership over it. •
Paper Wallets
• Some wallets allow downloading the code to generate new addresses offline.
Desktop Wallet
• Desktop wallets are programs that store and manage the private key for your
Bitcoins on your computer’s hard drive.
31
SITB3011 BLOCK CHAIN – UNIT 1
Mobile wallets
• A mobile wallet is a virtual wallet that stores payment card information on a mobile
device.
• They are quite convenient as it uses QR codes for transactions • Some mobile
32
SITB3011 BLOCK CHAIN – UNIT 1
Web Wallets
• They are ideal for small investments and allow quick transactions.
33
SITB3011 BLOCK CHAIN – UNIT 1
Bitcoin Transactions
• A full node is basically an electronic bookkeeper, and anybody in the world can set up
and run one.
Each node has a complete copy of the public ledger – that’s a record of every Bitcoin
transaction
34
SITB3011 BLOCK CHAIN – UNIT 1
4. Miners get the transaction from Mempool and start mining the block using a
consensus algorithm.
6. The chain validates the new block and every peer in the network will get the
blockchain with the new block added.
Mempool
• The Mempool (Shortcut for Memory Pool) is where the transactions stay until the
miner is ready to get them.
• In the bitcoin's blockchain, the miner prioritizes the biggest transactions over the
smallest ones.
35
SITB3011 BLOCK CHAIN – UNIT 1
• The code and the agreements contained therein exist across a distributed,
decentralized blockchain network.
• The code controls the execution, and transactions are trackable and irreversible.
• These actions could include releasing funds to the appropriate parties, registering a
vehicle, sending notifications, or issuing a ticket.
36
SITB3011 BLOCK CHAIN – UNIT 1
• That means the transaction cannot be changed, and only parties who have been
granted permission can see the results.
• Within a smart contract, there can be as many stipulations as needed to satisfy the
participants that the task will be completed satisfactorily.
• Participants must determine how transactions and their data are represented on the
blockchain.
organizations that use blockchain for business provide templates, web interfaces,
and other online tools to simplify structuring smart contracts.
Once a condition is met, the contract is executed immediately. Because smart contracts are
digital and automated, there’s no paperwork to process. No time spent reconciling errors
that often result from manually filling in documents.
Security
Blockchain transaction records are encrypted, which makes them very hard to hack.
Moreover, because each record is connected to the previous and subsequent records on a
distributed ledger, hackers would have to alter the entire chain to change a single record.
Savings
Smart contracts remove the need for intermediaries to handle transactions and, by
extension, their associated time delays and fees.
37
SITB3011 BLOCK CHAIN – UNIT 1
Smart contracts can be used across industries to streamline and automate doing business
around the world.
automated system
Real Estate
38