In the first part, we have discussed the basic principles and key features of blockchain and dealt with some of the most common questions. Now, we will address some more questions related to blockchain technology.
More Questions and Answers
Q: What if someone does not confirm the correct transactions and thus restricts the execution of transactions?
A: Failure to confirm the correct transaction may not always be intentional. This can happen even if someone keeps a different database than the others, for example as a result of an error. To be able to answer, we need to look at how blockchain handles the storage of information and how it ensures the integrity of the stored data. First, imagine a transaction system that consists of not just four friends, but has millions of people. If we always waited for confirmation by an absolute majority, the system would be very inefficient. When designing the blockchain, a possible extension was already taken into account and a different method was devised. The original metrics for the number of participants were converted to the computing power of the entire system. This means that in order for the transaction to be verified, a computing power representing the participation of at least 51% of the members (so-called hashrate) must be used. The degree of computational power is given by the complexity of a mathematical problem, the solution of which is computationally demanding. And since the state of the participants changes dynamically throughout the system, the level of complexity of solving this mathematical problem also changes. The process of confirming transactions is called mining, and the people who performed the verification are called miners.
Transaction verification takes place in several steps:
- Verification of the digital signature of the transaction.
- Verification of the account balance against the transferred value.
- Performing a calculation to find the appropriate pattern.
- Issuance of transaction verification information (block).
Thus, we know that the block contains an input value to the hash function that serves as proof of the transaction confirmation, because we know that the miner in question had to make a sufficient effort (use computational power) to obtain the required value. The block is then sent to all participants. Each participant takes a given block, takes the given value, calculates its hash and verifies it. Furthermore, the miner looks for which transaction the block is evidence of and considers this transaction confirmed. Therefore, if the block itself is valid, the recipient saves it in his local database. However, saving is not just inserting a received block next to another block, but the individual blocks are chained together. Chaining works in such a way that the currently received block also contains a value, which includes a hash of the previously issued block. When creating a new block, the value of the last issued valid block is taken and it is included in the new block. This creates a link to the previous block. The chaining process creates a database with linked blocks, called a blockchain.
Q: What is the purpose of chaining?
A: We have shown that each of the participants in our transaction system maintains its own database of confirmed transactions (blocks). If Daisy has a different database than Carl, one of these is invalid and it will be the one where the blocks do not follow each other, because they are not chained. Therefore, chaining plays an important role. If someone wanted to intentionally falsify the database to replace the last 5 blocks with their own consecutive blocks, they would have to expend immense computing power, which would represent more than 50% of the computing power of the entire blockchain system (a so-called 51% attack). This is very unlikely to happen because of all the resources needed to achieve this. The whole integrity of the blockchain database is thus strongly protected and it remains immutable.
Q: What is the motivation of the miners?
A: The larger the system, the more computing power the mining process requires. This is, of course, associated with the high financial cost of electricity consumption. So what is the motivation of the miners? The blockchain is set so that everyone who creates a transaction must pay a fee for it, which belongs to the miner who validates the transaction. At the same time, each miner receives a fixed reward for creating a valid block. Thus, the main motivation of the miners is to receive a reward.
Q: How do others know how much Daisy has in her account?
A: Because everyone can keep all the blocks in their own database, they know how many units are in each of the accounts in the system.
Q: What if Daisy has exactly 1,000 units on her account and creates two transactions at once, sending 1,000 units to Betty in one transaction and 1,000 units to Carl in the other?
A: If two different transactions are sent from one account, two different blocks are created at the same time. As soon as both blocks are received, they are divided into two parallel branches at the location of the last block in the blockchain database. The growth of the database continues by issuing more new blocks and gradually chaining them into individual branches, depending on which block they follow. The moment one branch starts to be longer than the other, the shorter branch is discarded and only the longer branch is continued. What does this mean in practice? In order for the recipient of a transaction to be sure that the amount actually belongs to him, he will wait for the release of a few more blocks, which will confirm that these branches will not be discarded. That’s the reason why several confirmations are typically needed for a valid transaction.
Q: What if Betty says one day that she never received those 1,000 units from Daisy?
A: You can just check the database and find a block confirming the transaction, which shows the transfer of 1,000 units from one account to the other account. Due to the strong protection of database integrity, we know that it is highly unlikely that the transaction would not take place.
So far, we have discussed the basic principles and key features of blockchain and dealt with some of the most common questions. In the next part, we will focus on smart contracts, advantages and disadvantages of blockchain technology and uses of blockchain.