Bitcove Blog

News and updates from the Ireland's leading cryptocurrency exchange

25-03-2021

What is a blockchain?

A blockchain is a decentralised, trusted database shared across a network of computers. Any information added to this network is extremely difficult to change. To date, blockchain technology has mainly been used as a transaction ledger for cryptocurrencies. However, there are a multitude of new, emerging uses for the technology.

Blockchain networks make constant checks to ensure all copies of the database are identical. Each member (computer) on the network is called a node. All blockchain networks require all transactions that occur on the network to be validated (checked to prove information is accurate). Each node plays a role in validating the network data.

There are a number of different validation methods used to secure blockchain networks, the most widely used and well known being Proof of Work (a.k.a. mining), the underlying mechanism to Bitcoin’s security. The concepts mentioned above can seem quite daunting and confusing. Below, we will take a closer look at just how this method functions in as simple terms as possible. We will also examine the strengths and potential drawbacks of Proof of Work validation.

What is Proof of Work Validation/Mining?

Proof of Work (PoW)

Transaction information within a Proof of Work (PoW) blockchain (Bitcoin for example) is stored in individual blocks that are connected in a chain. Simple right? To create each new block, members on the network compete against one another to solve extremely difficult equations using high powered computer processors. This process is known as ‘mining’. Each transaction that occurs on the network is registered to a block with a timestamp. Users of a blockchain pay a fee with each transaction sent. The transaction is then communicated to the decentralised network where miners employ their computing power to validate it (along with the rest of the block). New blocks can only be added at the rate they are being mined. The higher the fee paid, the quicker the transaction will be processed and added to the blockchain. This is the cause for delays experienced when sending and receiving cryptocurrencies.

Mining requires a lot of energy in the form of computer processing power and takes a lot of time. Miners compete amongst themselves to solve increasingly difficult equations on a trial-and-error basis. When a potentially correct solution to the equation is found, 51% of the network needs to agree it is correct before the block of transactions is added to the decentralized, shared ledger. This is known as a consensus mechanism.

Miners are rewarded for figuring out this equation in the form of a transaction fee (paid by the senders of any given transaction - in the form of Bitcoin in this example +block reward?). Miners receive this reward once the correct answer they have submitted is validated by the rest of the network. It is important to note that only successful miners who decipher the correct answer are rewarded. All the excess mining energy essentially goes to waste. As more blocks are added to the chain the equations increase in difficulty. As a result mining time and expense grows too. This disincentivizes miners attempting to cheat the system by adding incorrect information to the blockchain. This will be discussed in more detail below.

Miner
PoW: Protective Mechanisms

It is impossible to add a new block to the blockchain without first deciphering the associated algorithmic equation. This process protects the network from bad actors adding unwanted and incorrect data to the network. Each new block that is formed has a unique ‘fingerprint’ known as a hash. If any data within the block is changed, the hash will change too. Even the tiniest alterations to the block data will result in a completely new hash. Each block contains the hash of the preceding block along with its own hash. Let’s look at a visual example:

Example 1

Above, we have 5 blocks labelled A-E. The 3 digit numbers represent hashes (real hashes are much more complex than this). Block B contains the hash of Block A (443) along with its own hash (153). The rest of the blocks follow this logic.

If we were to change Block A in any slight way - the hash would completely change too (see below). This leads to the whole blockchain being invalid.

Example 2

If a malicious attempt was made to alter data within a block, the attacker would have to change each following block too. This would require a huge amount of processing power making such attacks expensive and time consuming, if not close to impossible. This protects Proof of Work blockchain networks from external attacks by keeping incurred costs greater than potential rewards for potential hackers. PoW protocol relies on human-self-interest to maintain integrity of the network.

Issues with Proof of Work Validation:

To decipher the equation that will add a new block to the blockchain, competing miners use computer processors to essentially ‘guess’ the answer. When a satisfactory answer is found, only the processor (node) that submitted it is rewarded. This led to the development of large-scale ‘mining farms’ where rich investors created warehouse sized processors to mine Bitcoin and other cryptocurrencies (see photo below).

Bitcoin Miners

As a response, ‘mining pools’ developed. These are groups of smaller miners who pool their processing resources together and split any rewards they get. As mentioned above, only successful miners receive cryptocurrency for their efforts resulting in massive energy wastage in the form of electricity used to power unsuccessful mining equipment. This has particular relevance in the current global environmental crisis.

Mining Pools and 51% Attacks:

Mining pools also exposed a potential flaw in the PoW system. Blockchains rely on consensus mechanisms to be validated. 51% of the members (a.k.a. nodes) need to confirm each transaction as valid before it can be submitted to the blockchain. Cryptocurrencies and blockchains are inherently decentralized and distributed, meaning there is no central governing authority who can permit or deny access to miners. This leaves the possibility of small mining pools with malicious intentions banding together with similarly minded individuals. Unfortunately, this issue comes hand in hand with decentralization. If there was such an entity that could prevent access to certain individuals - the network was never decentralized to begin with.

To put it in simple numbers, two mining pools that consist of 25% and 26% of the network respectively could easily combine to gain consensus over the entire network. This allows them to easily confirm invalid/fraudulent transactions as valid (e.g. sending the same single bitcoin to 2 different people). Although unlikely, mining pools increase the likelihood of malicious actors gaining this ability.

Summary:

Proof of Work (PoW) mechanisms allow for blockchain security by providing an incentive for miners to abide by predetermined rules in the network. Miners expend high levels of processing power and electricity to secure the network but are rewarded through transaction fees in the form of blockchain tokens (e.g. Bitcoin) for their initial investment by validating network transactions. Unfortunately, only miners who decipher the correct ‘hash’ for each block are rewarded.

The energy used trying to solve this equation by the rest of the miners goes to waste. This discourages bad actors attempting to alter the data on the network but has led to environmental concerns regarding the efficiency of PoW systems.

PoW mechanisms ensure a very high level of security for the blockchain network however they are not without flaw. The inception of mining pools has led to the possibility of 51% attacks on such networks. Although unlikely and both difficult and costly to employ, it is not outside the realm of possibility.


What do you think of Proof of Work validation? How does it stack up to alternative methods?

Reach out to us via our social media pages: