A fork is the classic development of open source software. Since open source software is of course freely accessible and downloadable by everyone, everyone has the possibility to make their own copy of the software and to modify it for their own purposes. That would have forced the software.
Modifying the software is by no means a malicious intervention, but even an elementary and desirable part of open source projects. Users with programming knowledge can add new functionalities according to their own needs – so different distributions of a software can exist.
What do forks have to do with blockchains?
Starting from a public blockchain like that of the bitcoin, it is ultimately based on open source code that can be modified locally by developers as described above. However, it is essential with blockchain technologies that the network participants agree on certain points. So it would be problematic if some miners in the network use e.g. the SHA-256 hash function and other network participants use a different hash function. After all, you don’t just want to write transactions in your own “household book”, but to carry them out in such a way that they are recognized by as many network participants as possible.
In practice, this is as follows:
- There is a generally accepted Bitcoin version.
- Users want new functionalities, e.g. an increase in the block size to solve capacity problems.
- Any user copies the current Bitcoin software and modifies it with a higher block size.
- He makes the software available to other users, who can also use it.
- Now there are two versions of Bitcoin software on the network and users can decide which one to use.
But attention: It is important to differentiate between blockchain forks and forks of software. While forks are used in the latter case to develop new or additional services based on existing ones, forks in the blockchain context rather aim to represent an alternative.
Forks must be classified in particular in terms of their effect on the existing software or on the blockchain network:
Types of Forks
To understand the explanations, you should know what Nodes is all about. Briefly explained, the nodes store the blockchain as network nodes and make it available to the network. In the best case, the current consensus of the blockchain, i.e. the most current transaction history, is stored decentrally on all nodes.
All nodes in the network must be operated with compatible software so that they can communicate on a blockchain. If an amendment proposal is submitted, there are two ways to carry out the fork:
A Soft Fork is characterized by its backwards compatibility. So there may be nodes in the network that work with the new software. This does not lead to compatibility problems: The nodes with the old software also accept the opinions of the users who have now opted for the new software. On the other hand, users want to establish their standard with the new software and therefore rely on their new method for all blocks.
As soon as the majority in the network is reached, all nodes agree on the new blocks.
This type of fork is not backward compatible – and therefore brings special challenges to guarantee consensus in the network. Existing nodes would have to update their software in order to take the new blocks into account (with the Soft Fork, the existing nodes could simply take the new blocks into account due to their compatibility). The incompatibility of the versions leads to the fact that the network can be split to a certain extent: Users who are in favour of or against acceptance of the changes will then operate on different block chains. This is called a blockchain fork (not comparable to a software fork). It is important to emphasize that a new, stable blockchain is not formed with every hard fork. Ethereum now has five Hard Forks behind it and only one of them has formed a new blockchain with Ethereum Classic.
How is a fork performed?
Let’s have a look at a fork like Bitcoin. The Bitcoin Core Team may be able to suggest changes – but not enforce them alone. In the end, the miners decide which blockchain they follow. This ensures decentralisation, as the network is also left the decision-making authority here. The Core Team can certainly push ahead with further developments – but it has to pitch again and again before the miners and hope for acceptance.
In the past, Ethereum and Ethereum Classic have indeed been a decisive split in the Ethereum Blockchain: After the DAO hack, the community intensively discussed reversing the transfer of the hacked coins by agreeing on a blockchain that does not include this transfer. Of course, option A) hackers may keep their loot with option B) action of the hacker will be reversed incompatible. The procedure therefore requires a hard fork. And as long as 100% of the participants do not agree on a version, the blockchain is split. This happened because there are now two Ethereum blockchains: Ethereum Classic (without hard fork: the hacker remains in possession of the stolen coins) and Ethereum (with hard fork: unwanted transaction was undone).
Miner Activated fork
In this case, the miners in the network decide whether a fork is performed. You signal that you want to perform the fork by appending this information to confirmed blocks. If within the last 1000 blocks a sufficient amount of miners has signalled the fork, the changes are enforced. For example, the new version is valid from 75% approval, from 95% even old blocks that are not marked with the new version are rejected.
User Activated Soft Fork (UASF)
The User Activated Soft Fork (UASF) is a fork that is brought about by a majority decision among the full nodes. It is scheduled to a certain date on which the majority of the full nodes must agree in order for the fork to actually take place.
Miner Activated Soft Fork (MASF)
With a Miner Activated Soft Fork (MASF), the miners decide on the fork with their computing power as voting rights and initiate it. This makes the process more efficient, as the full nodes can accept the changes afterwards. However, MASF involves risks because the network relies on computing power as a benchmark. For example, the computing power can tell you that the soft fork is taking place, but the miners actually continue to work with the old version without the soft fork.