• Ei tuloksia

3. THEORETICAL BACKGROUND

3.3 Blockchain Technology in Supply Chains

3.3.1 Blockchain technology

The fundamental unit of a blockchain is a transaction, which represents a transfer of value from one address to another. Each sender and recipient have a unique identifier called address that in practice can be a reusable or new generated for each transaction, depending on the characteristics of the blockchain (Bashir, 2017). A list of transactions are recorded in a block through a process called mining, creating a ledger over a given period. In every blockchain, the size, period, and triggering event for blocks is different (Laurence, 2017).

Thereby, a block is an aggregated set of data that can be identified using a unique cryp-tographic hash or digital fingerprint, as is shown in ¡Error! No se encuentra el origen de la referencia.. All blocks contain a hash of the previous block, so blocks can form a chain from the first block ever or genesis block to the formed block (Kovary, et al., 2018).

The blocks also contain a timestamp, a nonce and a Merkel root (Tate & Daniel, 2017).

A nonce is an arbitrary integer, which only can be used once, necessary for producing the Proof-of-Work (PoW) algorithm to reach consensus during the block creation (Kovary, et al., 2018). The Merkel root is related with a set of valid transactions that are hashed and encoded into a Merkle tree structure (see Figure 14) (Tate & Daniel, 2017). This structure is based on a full binary tree of hash values where at the bottom level each transaction has a node containing its hash value (Kovary, et al., 2018). Afterward, the tree is built in a manner that the hashes of the transactions are organized into pairs of twos,

concatenated together, and then hashed again. The same is done to each set of outputs until something like a tree is formed, where the hash at the very top of the tree is called the Merkle Root (Pacia, 2017). The Merkel tree structure enables an efficient and fast validation of transactions without revealing the exact content, whereas the chain of block structure allows demonstrate integrity by tracking back from any point in the hash-based chain to the genesis block (Tate & Daniel, 2017; Kovary, et al., 2018).

Figure 13 : Blockchain chain of blocks (Tate & Daniel, 2017)

Figure 14: Block configuration (Tate & Daniel, 2017)

When a transaction is created, it has to be sent to the blockchain network to be processed in order to be validated and incorporated in a chain of blocks (Verhoelen, 2017). The blockchain is a set of nodes forming a network with the same communication protocol.

A node can be a personal computer or a supercomputer, which processes the transactions (Preukschat, 2017). It can be located in any part of the world and can be operated by anyone. In addition, each node contains a complete record of all the transactions that were ever recorded in that blockchain (Laurence, 2017).

The nodes can propose and validate transactions by mining, and secure the blockchain by following a consensus protocol (Bashir, 2017). To process transactions and validate them by append them to the history in blocks, the node is required to solve a complex mathe-matical problem (see Figure 15). This approach is called Proof-of-Work (PoW), a com-putational effort to proof that enough resources have been spent in order to build a block (Kovary, et al., 2018). The main idea under this concept is that a random node is selected every time to create a new block. In this model, nodes compete with each other in order to be selected in proportion to their computing capacity (Bashir, 2017).

Figure 15: How blockchain works (Laurence, 2017)

The PoW algorithm is used as consensus algorithm in the blockchain. The consensus is the process of developing an agreement among a group of commonly mistrusting share-holders, presenting a single version of truth that is agreed upon by all parties without the requirement of a central authority. Thereby, blockchain is an honest system that self-cor-rect without the need of a third party to enforce the rules (Laurence, 2017).

Moreover, this consensus must provide an up-to-date copy of all transactions in real time to all the nodes of the network (Laurence, 2017). This allows demonstrate the integrity of the blockchain by tracing back from any point in the hashed chain to the genesis block, supposing no single point of failure by design (Verhoelen, 2017; Tate & Daniel, 2017).

Thereby, the blockchain can only be written by consensus and once the records are added onto the blockchain are immutable (Tate & Daniel, 2017).

The cryptographic features of the blockchain ensure the impossibility of changing trans-actions in the history without invalidating the following ones (Verhoelen, 2017). Thus, the blockchain is secure, providing the confidence that computer attacks, failures or fal-sifications cannot be committed (Tate & Daniel, 2017). Because of that, the aim of block-chain is to provide an unchangeable, secure and perfectly verified history (Verhoelen, 2017).

In the blockchain network, there is no central node processing and distributing the data (Kovary, et al., 2018). The net of nodes are forming a decentralized P2P network where all the nodes are equal to each other resulting in a distributed system (see Figure 16). In such a manner, even if a node fails, the data could reach those others to which it is con-nected by alternative routes (Crowe, 2016). Thus, the blockchain is designed to be highly available and can be operated with an infinite amount of nodes (Verhoelen, 2017).

Figure 16: Types of net models (Crowe, 2016)

In the last few years, the blockchain networks have evolved into different types, allowing divide them according to their attributes. This conduces to a classification of blockchains based on the following features (Bashir, 2017):

Public, private and semiprivate blockchains

The public blockchains, also known as permission-less ledgers, are publicly open and anyone can participate as a node to read and write on it. On the other hand, private blockchains are only open to a consortium or group of individuals or organizations that has decided to share the ledger among themselves. Finally, the semiprivate block-chain is a combination of both; where a part is private and controlled by a group of individuals while the public part is open free for participation (Bashir, 2017).

Permissioned and permission-less ledger

A permissioned ledger blockchain is one where all the participants of the network are known and already trusted. Thus, instead of a consensus mechanism to ensure trust, an agreement protocol is used to keep a shared version of trust about the state of the records (Bashir, 2017).

The permission-less blockchain, all users maintain a copy of the ledger on their local nodes and use a distributed consensus mechanism in order to reach a decision about the eventual state of the ledger (Bashir, 2017).

Tokenized and tokenless blockchains

The standard blockchains are tokenized, in other words, they generate cryptocurrency because of a consensus process via mining or via initial distribution. Furthermore, the tokenless blockchains just share data among various already trusted parties (Bashir, 2017).