Uploaded by Roba ahmed

blockchain (2).docx (1)

advertisement
KING KHALID UNIVERSITY
COLLEGE OF COMPUTER SCIENCE
SEMINAR TITLE
BLOCKCHAIN TECHNOLOGY
By:
Amjad Abdullah Alqahtani, 437804250
Atheer Awad Alqadi, 437804251
Fawziah Tariq Misfer, 437804434
Ruba Ahmed Almohya, 437805795
Supervised by:
Ms. Syeda Meraj Bilfaqih
This Documentation is submitted in partial fulfillment of the requirement
of the course Seminar 481CSM-1 in Computer Science curriculum
Academic Year 2020/1440-1441 (Semester-II)
Acknowledgment
When we did this report, we had to take help from many people this makes us grateful, so they
deserve our thanks. The first is our family there support us in many things. And we would like
to show our gratitude to MS. Syeda Meraj for giving us a good guideline for the report and give
us her trust to do what we like. We thank all the people for their help, directly and indirectly,
to complete our report.
Group Members
vi
ABSTRACT
Blockchain is essentially а distributed database of records or public ledger of all transactions or
digital events that have been executed and shared among participating pаrties. Eаch transaction
in the public ledger is verified by consensus of а majority of the participants in the system. Once
entered, information can never be erased. The blockchain contains а certain and verifiable
record of every single trаnsаction ever mаde. Bitcoin, the decentrаlized peer-to-peer digital
currency, is the most popular exаmple thаt uses blockchаin technology. The digitаl currency
bitcoin itself is highly controversiаl but the underlying blockchаin technology hаs worked
flawlessly аnd found wide rаnge of аpplicаtions in both finаnciаl аnd non-finаnciаl world. The
mаin hypothesis is thаt the blockchаin estаblishes а system of creаting а distributed consensus
in the digitаl online world. This аllows pаrticipаting entities to know for certаin thаt а digitаl
event hаppened by creаting an irrefutаble record in а public ledger. It opens the door for
developing а democrаtic open аnd scаlаble digitаl economy from а centrаlized one. There аre
tremendous opportunities in this disruptive technology, аnd the revolution in this spаce hаs just
begun. This white pаper describes blockchаin technology аnd some compelling specific
аpplicаtions in both finаnciаl аnd non-finаnciаl sector. We then look аt the chаllenges аheаd
аnd business opportunities in this fundаmentаl technology thаt is аll set to revolutionize our
digitаl world.
vi
Contents
Acknowledgment ......................................................................................................................................i
ABSTRACT ................................................................................................................................................. ii
Contents .................................................................................................................................................. iii
List of Figure ............................................................................................................................................ iv
List of Table ............................................................................................................................................. iv
List of Acronyms, Abbreviations and Symbols ......................................................................................... v
CHAPTER ONE: INTRODUCTION .............................................................................................................. 1
1.1
OVERVIEW ............................................................................................................................... 1
1.2
OBJECTIVE ............................................................................................................................... 1
1.3
MOTIVATION & CHALLENGES ................................................................................................. 2
1.3.1 Motivation: ............................................................................................................................. 2
1.3.2
1.4
Challenges: ...................................................................................................................... 2
SUMMARY ............................................................................................................................... 3
CHAPTER TWO: LITERATURE REVIEW ..................................................................................................... 4
2.1
HISTORY OF BLOCKCHAIN ....................................................................................................... 4
2.2 BLOCKCHAIN IN SAUDI ARABIA ......................................................................................................... 5
2.3
CHARACTERISTICS OF BLOCKCHAIN ........................................................................................ 5
2.4
TYPE OF BLOCKCHAINS............................................................................................................ 6
2.5
Summary ................................................................................................................................. 7
CHAPTER THREE: ARCHITECTURE & APPLICATIONS OF BLOCKCHAIN .................................................... 8
3.1
ARCHITECTURE ........................................................................................................................ 8
3.1.1
Block ................................................................................................................................ 8
3.1.2
Digital Signature .............................................................................................................. 9
3.1.3
Blockchain architecture components.............................................................................. 9
3.2
WORK OF THE BLOCKCHAIN.................................................................................................. 10
3.3
ALGORITHMS OF BLOCKCHAIN ............................................................................................. 11
3.4
THE APPLICATION OF BLOCKCHAIN ...................................................................................... 13
3.5
SUMMARY ............................................................................................................................. 14
CHAPTER FOUR: SUMMARY .................................................................................................................. 15
4.1 CONCLUSION ................................................................................................................................... 15
4.2 FUTURE WORK ................................................................................................................................ 15
REFERENCE ............................................................................................................................................ 16
vi
List of Figure
FIGURE 1- 1 .............................................................................................................................................................. 1
FIGURE 2- 1 .............................................................................................................................................................. 4
FIGURE 2- 2 .............................................................................................................................................................. 6
FIGURE 2- 3 .............................................................................................................................................................. 7
FIGURE 3- 1
FIGURE 3- 2
8
8
List of Table
TABLE 1 .................................................................................................................................................................... 2
TABLE 2 .................................................................................................................................................................. 11
TABLE 3 .................................................................................................................................................................. 13
vi
List of Acronyms, Abbreviations and Symbols
SAMA
Saudi Arabian Monetary Authority
UAECB
United Arab Emirates central bank
P2P
a peer-to-peer
R3
Reduce, reuse and recycle
PoW
Proof of Work
PoS
Proof of Stake
DPOS
Delegated proof of stake
PBFT
Practical byzantine fault tolerance
UNL
Unique Node List
IFTTT
if-this-then-that
IoT
the Internet of Things
vi
CHAPTER ONE: INTRODUCTION
1.1 OVERVIEW
Blockchain is an innovation that can be customized to record money related exchanges as well
as for all intents and purposes and everything of significant worth as it is upright computerized
ledger of monetary exchanges. Blockchain is a period stepped arrangement of unchanging
records of data, that are put away in a permanent database. It is a dispersed, decentralized,
public ledger. Its data is managed by clusters of computers called nodes that are not owned by
one entity. Blockchain is called a decentralized ledger in light of the fact that the information
in it is open for anybody to see. The ledger is a bundle of blocks (changes or transactions) that
are chained together. It is numerically difficult to alter the existing ledger, in light of the fact
that blockchain uses cryptographic algorithms. Blockchain is the back-linked record of a block
(exchanges), which are timestamped, changeless and in a severe request.
Figure 1- 1
1.2 OBJECTIVE
While blockchain is most famous for its role in facilitating the rise of digital currencies over
the past several years, there are also many other non-cryptocurrencies uses for this technology.
In our Blackchin study, we discuss that later. Our objectives of this seminar study are:

To give a brief history of the Blockchain, Characteristics, Types, algorithms used.

To provide the architecture of Blockchain.

To discuss the application of Blockchain in various domains and the future of this
technology.
14
1.3 MOTIVATION & CHALLENGES
1.3.1 Motivation:
blockchain applications have been one of the most rapidly emerging fields of computer science,
because of the wide use of the internet or online mechanism in today’s organizations. Below
are our motivations of choosing this topic for the seminar:
-
It is inexpensive - A large portion of the customary monetary models that are accessible
in the market are costly, notwithstanding, with blockchain it is reasonable.
-
Less exchange time - An individual can send, get cash and money related archives inside
several minutes, this decreases the weight of hanging tight for a considerable length of
time together.
-
Financial proficiency is expanded - Decentralized blockchain permits one to make
exchanges from individual to individual without the association of the outsider. This
assistance sets aside a great deal of cash while making exchanges, in contrast to
customary banks.
-
Protect organizations from extortion - The blockchain is open-source records which is
the reason it is anything but difficult to distinguish if misrepresentation has occurred
since each exchange is recorded on them [3].
1.3.2 Challenges:
Despite the great potential of blockchain, it faces numerous challenges, which limit the wide
usage of blockchain. We enumerate some major challenges and recent advances as follows.

Scalability:
With the number of transactions increasing day by day, the blockchain becomes bulky. ,
due to the original restriction of block size and the time interval used to generate a new
block, the Bitcoin blockchain can only process nearly 7 transactions per second, which
cannot fulfill the requirement of processing millions of transactions in a real-time fashion.
Meanwhile, as the capacity of blocks is very small, many small transactions might be
delayed since miners prefer those transactions with a high transaction fee.

Privacy Leakage:
Blockchain can preserve a certain amount of privacy through the public key and private
key. Users transact with their private key and public key without any real identity exposure.
However, that blockchain cannot guarantee transactional privacy since the values of all
transactions and balances for each public key are publicly visible. Besides, the recent study
has shown that a user’s Bitcoin transactions can be linked to reveal user’s information.

Fake blocks:
14
it is possible to generate fake blocks by the network nodes or generate transactions that are
reverse confirmed. Rapid generation of blocks is possible by increased power consumption,
resulting in legitimate blocks not being able to get their share of blockchain network
resources.

Energy consumption:
An important challenge of blockchain networks is energy consumption. These transactions
consume a huge amount of energy. It is estimated that each Bitcoin transaction consumes
80,000 times more energy as compared to a credit card transaction [3].
1.4 SUMMARY
In this chapter, we introduced the concept of blockchain, we also mentioned the objectives of
this seminar, the motivations that led us to choose this topic to talk about and we discussed the
challenges that blockchain facing nowadays. In chapter two, we are going to discuss the type
and the history of blockchain, and some algorithms using in this technology. Chapter three will
talk about the architecture and applications of blockchain. the fourth chapter is about the
summary of the seminar followed by a discussion of the future of the blockchain.
14
CHAPTER TWO: LITERATURE REVIEW
2.1 HISTORY OF BLOCKCHAIN
Blockchain has the potential to grow to be a bedrock of the worldwide record-keeping systems
but was launched just 10 years ago. It was created by the unknown persons behind the online
cash currency bitcoin, under the pseudonym of Satoshi Nakamoto [8].
Figure 2- 1
14
2.2 BLOCKCHAIN IN SAUDI ARABIA
In 2018 Saudi Arabia has warned its citizens against dealing or investing in virtual digital
currencies as they are outside the scope of the regulatory umbrella within the Kingdom of Saudi
Arabia ([6],[7]).
But with the importance of technology and its rapid development and to achieve the goals of
Vision 2030 and digital transformation, it has been:
1. In 1/2019 Launching “ABER” project, the common digital currency between the Saudi
Arabian Monetary Authority (SAMA) and the United Arab Emirates central bank
(UAECB) in 2019.
2. In 4/2019 Inaugurated the first forum of digital transformation and blockchain in Saudi
Arabia.
2.3 CHARACTERISTICS OF BLOCKCHAIN
1- Cannot be corrupted:
Every mode on the network has a copy of the digital ledger. To add a transaction every
node needs to check its validity. If the majority thinks it's valid, then it's added to the
ledger. This promotes transparency and makes it corruption – proof.
2- Decentralized technology:
The network is decentralized meaning it doesn't have any governing authority or a single
person looking after the framework. Instead, a group of nodes maintains the network
making it decentralized.
3- Enhanced security:
As it eliminates the need for a central authority, no one can just simply change any
characteristics of the network for their benefit. Also using encryption ensures another
layer of security for the system.
4- Distributed ledgers:
The ledger of the network is maintained by all other users of the system. This distributes
the computational power across the computers to ensure a better outcome.
5- Consensus:
Every blockchain thrives because of the consensus algorithms, the architecture is
cleverly designed, and consensus algorithms are at the core of this architecture, every
blockchain has a consensus to help the network make decisions.
6- Faster settlement:
Blockchain offers a faster settlement compared to traditional banking systems, this way
a user can transfer money relatively faster, which saves a lot of time in the long run [5].
14
2.4 TYPE OF BLOCKCHAINS
Every blockchain consists of a cluster of nodes functioning on a peer-to-peer (P2P) network
system. Every node in a network has a copy of the shared ledger which gets updated timely.
Each node can verify transactions, initiate or receive transactions and create blocks.
There are four types of blockchains:
1- Public Blockchain:
A public blockchain is a non-restrictive, permission-less distributed ledger system. 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. A node or user which is a part of the public
blockchain is authorized to access current and past records, verify transactions or do proofof-work for an incoming block, and do mining. The most basic use of public blockchains is
for mining and exchanging cryptocurrencies.
Examples: Bitcoin, Ethereum, Litecoin.
2- Private blockchain
a private blockchain is a restrictive or permission blockchain operative only in a closed
network. Private blockchains are usually used within an organization or enterprise where
only selected members are participants of a blockchain network. The level of security,
authorizations, permissions, accessibility is in the hands of the controlling organization.
Thus, private blockchains are similar in use as a public blockchain but have a small and
restrictive network. Private blockchain networks are deployed for voting, supply chain
management, digital identity, asset ownership, etc.
Examples: multichain and Hyperledger projects (fabric, sawtooth), Corda, etc.
Figure 2- 2
14
3- Consortium Blockchain
A consortium blockchain is a semi-decentralized type where more than one organization
manages a blockchain network. This is contrary to what we saw in a private blockchain,
which is managed by only a single organization. More than one organization can act as a
node in this type of blockchain and exchange information or do mining. Consortium
blockchains are typically used by banks, government organizations, etc.
Examples: Energy Web Foundation, R3, etc.
4- Hybrid Blockchain
A hybrid blockchain is a combination of the private and public blockchain. It uses the
features of both types of blockchains that is one can have a private permission-based system
as well as a public permission-less system. With such a hybrid network, users can control
who gets access to which data stored in the blockchain. Only a selected section of data or
records from the blockchain can be allowed to go public keeping the rest as confidential in
the private network. The hybrid system of blockchain is flexible so that users can easily join
a private blockchain with multiple public blockchains. A transaction in a private network
of a hybrid blockchain is usually verified within that network. But users can also release it
in the public blockchain to get verified. The public blockchains increase the hashing and
involve more nodes for verification. This enhances the security and transparency of the
blockchain network. Example: Dragon chain [2].
Figure 2- 3
2.5 Summary
In this chapter we give a background about blockchain, also the history of blockchain, then we
summarize the features of blockchain, blockchain types, some supported with a picture.
14
CHAPTER THREE: ARCHITECTURE & APPLICATIONS OF
BLOCKCHAIN
3.1 ARCHITECTURE
Blockchain is a series of blocks, which contains a list of transaction records like a conventional
public ledger. with a prior block hash held in the block header, a block owns only one parent
block. the blocks will be stored in children of the block’s ancestors. The first block of a chain
is called (genesis block) which has no parent block. We will talk about the internals of
blockchain [2].
Figure 3- 1
3.1.1 Block
contain a header and the body of the block as figuer3.2. So, the block header includes:
(i) Block version means which group of block validation rules to serve.
(ii) Merkle tree root hash: all the transactions hash value in the block.
(iii) Timestamp: is the current time as seconds in universal time.
(iv) n Bits: the valid block hash.
(v) Nonce: a 4-byte area, it usually starts at 0 and increases for every hash calculation.
(vi) Parent block hash: a 256-bit hash value, that points to the prior block.
Figure 3- 2
14
block body: is composed of a transaction and transaction counter. the block contains a
maximum number it depends on the size of each transaction and the block size. To validate the
authentication of transactions the Blockchain uses an asymmetric cryptography mechanism.
The digital signature is used in an untrustworthy environment based on asymmetric
cryptography.
3.1.2 Digital Signature
Each user has a pair of a private key and public key. The private key that will be kept in privacy
is used to sign the transactions. The digitally signed transactions are declared throughout the
whole network. The typical digital signature is included with two phases [2]:

signing phase

verification phase
3.1.3 Blockchain architecture components
These are the core blockchain architecture components:
Table 1
14
3.2 WORK OF THE BLOCKCHAIN
The Blockchain technology can do direct transactions among two sides without any
intermediary such as (bank). It is essentially a public database and, it is not owned by anyone
party, it is not stored on a single computer, but it is distributed and stored on computers across
the world. Blockchain works as a network of computers.
The blockchain technology's basic work is two things the first is gathering data (transaction
records) and the second is placing these blocks together in a chain with the use of cryptography.
If a transaction happens, this transaction information is shared with everyone on the blockchain
network. These transactions are singly timestamped and once these transactions are put together
in a block, they have again timestamped as a full block. Then, this complete block is added to
the chain in the blockchain network. and the other participants might also be appended to the
network at the synchronous (same time), but the timestamps care of the order in which the
blocks are added to the network. every block’s information is taken, and a hash function is
applied to it. The value is stored in the next block and so on.
the details of the transfer are recorded on a (public ledger) that anybody on the network and
sees in the existing financial system [4].
In table 2 is explained how the transaction of blockchain steep by steep:
The requested transaction to P2P network consisting of the
network contestant of computers knows as nodes.
The network of nodes validation the transaction and the
user's status using knows algorithms.
The block is broadcast to every party in the network
A verified transaction can involve cryptocurrency,
contracts, records, or other information.
14
Those in the network approve the transaction is valid
Once verified, the transaction is combined with other
transact create a new block of data for the ledger
The new block is then added to the existing blockchain, in
a way that is permanent and unalterable.
The transaction is complete.
Table 2
3.3 ALGORITHMS OF BLOCKCHAIN
There are several algorithms in the blockchain that we will discuss each one in detail:

Proof of Work (PoW):
This consensus algorithm is used to select a miner for the next block generation. Bitcoin
uses this PoW consensus algorithm. The central idea behind this algorithm is to solve a
complex mathematical puzzle and easily give out a solution. This mathematical puzzle
requires a lot of computational power and thus, the node who solves the puzzle as soon
as possible gets to mine the next block.

Proof of Stake(PoS):
This is the most common alternative to PoW. Ethereum has shifted from PoW to PoS
consensus. In this type of consensus algorithm, instead of investing in expensive
hardware to solve a complex puzzle, validators invest in the coins of the system by
locking up some of their coins as stake. After that, all the validators will start validating
the blocks. Validators will validate blocks by placing a bet on it if they discover a block
that they think can be added to the chain. Based on the actual blocks added in the
Blockchain, all the validators get a reward proportionate to their bets and their stake
increase accordingly.
14
In the end, a validator is chosen to generate a new block based on their economic stake
in the network. Thus, PoS encourages validators through an incentive mechanism to
reach to an agreement.

Delegated proof of stake DPOS:
The major difference between PoS and DPOS is that PoS is direct democratic while
DPOS is representative democratic. Stakeholders elect their delegates to generate and
validate blocks. With significantly fewer nodes to validate the block, the block could be
confirmed quickly, leading to the quick confirmation of transactions. Meanwhile, the
parameters of the network such as block size and block intervals could be tuned by
delegates. Additionally, users need not worry about the dishonest delegates as they
could be voted out easily. DPOS is the backbone of Bit shares.

Practical byzantine fault tolerance PBFT:
The practical byzantine fault tolerance algorithm in blockchain inherits many concepts
from its version used in distributed systems. The consensus is achieved, in this case, to
decide the validity of a block.
Nodes in the system share messages among each other to commit a block to the chain.
Malicious nodes, in this case, may broadcast tampered blocks, as a result, the block
which is considered valid by a maximum number of nodes is considered valid in its
entirety by the entire network.

Ripple:
is a consensus algorithm that utilizes collectively trusted subnetworks within the larger
network? In the network, nodes are divided into two types: server for participating
consensus process and client for only transferring funds. Each server has a Unique Node
List (UNL). UNL is important to the server. When determining whether to put a
transaction into the ledger, the server would query the nodes in UNL and if the received
agreements have reached 80%, the transaction would be packed into the ledger. For a
node, the ledger will remain correct as long as the percentage of faulty nodes in UNL is
less than 20%.

Tendermint:
is a byzantine consensus algorithm. A new block is determined around. A proposer
would be selected to broadcast an unconfirmed block in this round. It could be divided
into three steps:
1- Prevote step. Validators choose whether to broadcast a prevote for the proposed
block.
14
2- Pre-commit step. If the node has received more than 2/3 of prevote on the proposed
block, it broadcasts a pre-commit for that block. If the node has received over 2/3
of pre-commit, it enters the commit step.
3- Commit step: The node validates the block and broadcasts a commit for that block.
if the node has received 2/3 of the commits, it accepts the block. In contrast to PBFT,
nodes must lock their coins to become validators ([2], [10]).
Tolerated
power of the
adversary
Table 3
3.4 THE APPLICATION OF BLOCKCHAIN

Blockchain Smart Contracts
These are digital contracts that follow the if-this-then-that (IFTTT) that enables them to be selfexecuting for these contracts. In reality, an intermediary ensures that all parties follow the terms.
The blockchain also ensures that all ledger partners know the contract details and that
contractual terms implement automatically once conditions are met. in these smart contracts
can be used like property deals, insurance premiums, etc.

Blockchain for Real Estate
Blockchain technology is useful for a paper-record based industry as it allows records are stored
digitally to reduce any kind of fraud. Real estate chooses to select blockchain for main functions
such as payment, title, and escrow; this could create efficiencies and saving costs.

Blockchain for Digital Identities
14
Blockchain technology work to tracking and managing digital identities secure resulting and
useful in less fraudulent incidents.

Blockchain Financial Services
Blockchain technology is reworking the financial services. More aid is getting by useing this
technology, especially in back-office operations and to improve transparency.

Blockchain for the Internet of Things (IoT)
Blockchain technology provides scalability, privacy, and reliability in the IoT. also, it can be
used in tracking millions of linked devices, enable the processing of transactions and
coordination between devices. it's run on the devices in a safe ecosystem.

Blockchain-Based Payments
The Blockchain technologies make a new P2P environment of transfer the money. Blockchain
technology does not need a third-person or for a centralized party to control a cryptocurrency,
nor is there any type of limitation or rules of usage. Cryptocurrencies provide people all over
the world with immediate and safe money

Blockchain Healthcare
Blockchain technology in healthcare can be used cryptography and store health records in the
form of a private key that gives access only to specialized individuals [4].
3.5 SUMMARY
In this chapter, we have discussed architecture and the basic components of a blockchain
and who it is work and the applications of this technology.
14
CHAPTER FOUR: SUMMARY
4.1 CONCLUSION
In conclusion, blockchain became important day by day. It is an innovation that can be
customized to record money related exchanges as well as for all intents and purposes and
everything of significant worth. We can expect that in the coming decade a large number of
people using this technology. This seminar showed briefly the overview of blockchain
technology, also it highlighted the history of blockchain development and their characteristics.
the basic structure, applications in blockchain technology in different fields, and finally summary
and discuss the future blockchain in the future.
4.2 FUTURE WORK
Blockchain is an essential component of future transport over the network, and It will be used
in many fields. In the future, people will deal with each other directly without the need for a
third intermediary (the bank).
14
REFERENCE
[1] Bucharest, April 19-20, 2018, The 14th International Scientific Conference
eLearning and Software for Education.
An Overview of Blockchain Technology:
Architecture, Consensus, and Future Trends
[2] An Overview of Blockchain Technology: Architecture, Consensus, and Future Trends
[3] Data science central,11/3/2019 https://www.datasciencecentral.com/profiles/blogs/theimportance-of-blockchain-technology-and-decentralization
[4] Xenonstack,1/2/2018 https://www.xenonstack.com/blog/decentralized-applications/
[5] 101BLOCKCHAINS , 24/5/2018 https://101blockchains.com/introduction-to-blockchainfeatures/
[6] Saudi Arabian Monetary Authority, 29/1/2019 http://www.sama.gov.sa/arsa/News/Pages/news29012019.aspx
[7] Saudi Arabian Monetary Authority, 27/3/2018 http://www.sama.gov.sa/arsa/news/pages/news27032018.aspx
[8] Icaew,https://www.icaew.com/technical/technology/blockchain/blockchain-articles/whatis-blockchain/history
[9] Data flair,10/9/2019 https://data-flair.training/blogs/types-of-blockchain/
An Overview of Blockchain Technology:
Architecture, Consensus, and Future Trends
An Overview of Blockchain Technology:
Architecture, Consensus, and Future Trends
[10] Geeksforgeeks https://www.geeksforgeeks.org/consensus-algorithms-in-blockchain/
14
Download