Add Thesis

Energy Consumption and Security in Blockchain

Written by E. Borzi, D. Salim

Paper category

Master Thesis

Subject

Computer Science

Year

2020

Abstract

Thesis Blockchain: Blockchain is a distributed ledger technology (DLT), which has become more and more popular after the launch of the digital currency Bitcoin in 2009 [8]. To understand this technology, it is more practical to use cryptocurrency as an example, in this case Bitcoin. The total transaction history of Bitcoin is kept in the ledger. In simple terms, the Bitcoin ledger consists of announcements such as "I am Bob, I gave Sara X Bitcoin". In a group of five friends, it would be easy to maintain such a ledger without any complicated blockchain technology. All friends will jointly own this ledger and be able to add new transactions. Most importantly, friends will believe that all transactions are real because they are friends and trust each other. The problem that blockchain technology solves is when millions of strangers want to share the same ledger, not a group of five friends. Trust no longer reliably protects the ledger from dishonest transactions. A simple solution is to allow trusted public organizations to control ledgers and transactions, but this is the same as the banking system. The founder of Bitcoin's underlying blockchain technology discussed how this technology makes public decentralized digital currency possible [3]. Decentralization is contrary to the control of the ledger by a bank or other single institution, and all control rights belong to the people's participation in the ledger. To fully understand the basic structure of the blockchain, it is best to continue to take the digital currency as an example. All communication between "strangers" in the blockchain is peer-to-peer (P2P). Contrary to the classic client-server communication model, where a client requests data from the server, and P2P communication is carried out directly between computers [9]. The owner of the computer can be an individual or an organization. Blockchain is usually represented as a P2P network, where the connected computers (see Figure 1) are called peers or nodes. Every peer on the blockchain has a copy of the ledger. These peers are strangers to each other because they do not know each other's true identity, but each peer is known to others through its unique public key [8]. The public key is a long, unique sequence of numbers used to identify the peer and is important when providing a signature for the transaction. In the simple example of "I am Bob, I gave Sara X coins", the peer must provide proof that he is indeed Bob in the form of a signature. Each peer has two unique keys, which are used to sign transactions [1], the public key and private key are only known by the peer. The way these keys are related is that when a message is encrypted with a private key, it can only be decrypted with a public key. This relationship is used for digital signatures by encrypting part of the transaction using the private key. 2.2 Consensus in Blockchain In computer science, there is a popular problem called the Byzantine Generals Problem [12]. The background story is that several generals, each with their own soldiers, are planning to attack a city. The premise is that the attack can be successful only if most generals agree on the same strategy. All communications between the generals are done by messengers. The problem is that some generals are traitors and spread misinformation. If this kind of misinformation is spread to many generals, it may prevent agreement on the same strategy and lead to complete failure. Generals must follow certain rules to ensure agreement and tolerance for opponents. The tolerance of opponents enables loyal generals to receive misinformation from traitors and discard them. This is the fundamental problem solved by the blockchain consensus mechanism. The node is the general, and the attack strategy is the ledger. All nodes hope to reach agreement on the same ledger. Dishonest nodes, traitors, can never influence the ledger because they are overtaken by honest nodes. The rule of thumb is that the ledger is always determined by the content agreed by the majority, and the consensus determines the official ledger. As mentioned in the previous chapter, trust is not considered a reliable source of protection for the ledger. In addition, centralized control of public ledgers is not the goal of blockchain. Through the use of consensus mechanisms, especially the use of incentives, trust and centralized control are avoided [1]. Creating incentives for maintenance is an important part of the consensus mechanism. Incentive measures involve more nodes to maintain the network and help spread consensus [13]. An example of incentive measures is the transaction fees of digital currencies [11]. Whenever a transaction broadcast by a node must include a transaction fee, the fee is provided as a reward to anyone who includes the transaction in the block. Nodes that collect transactions into blocks will be rewarded with all transaction fees. If the blockchain forks, the peer who creates the next block must carefully choose the chain to continue. If the block is added to the wrong chain and will be discarded later, then the reward will be lost because there has never been a transaction according to the ledger. The longest chain is the chain that each peer agrees to, but it may happen that the new chain becomes the longest chain and the previous longest chain is discarded. Transaction fees also incentivize nodes to verify previous blocks on the chain. If the previous block is invalid, the node can continue on the fork. Peers verify the block by controlling that each transaction in the block is correctly signed and the trader has enough balance. The balance of the peer can be calculated by browsing the ledger. Read Less