Skip to content

Latest commit

 

History

History
166 lines (128 loc) · 18.3 KB

appdx-forks-history.asciidoc

File metadata and controls

166 lines (128 loc) · 18.3 KB

Appendix A: Ethereum Fork History

Most hard forks are planned as part of an upgrade roadmap and consist of updates that the community generally agrees to (i.e. there is social consensus). However, some hard forks lack consensus, which leads to multiple distinct blockchains. The events that lead to the Ethereum / Ethereum Classic split is one such case, and are discussed in this section.

Note

The opinions expressed in this section are controversial. Contributions were made by, and are presented from the perspective of, the Ethereum Classic community.

Ethereum Classic (ETC)

Ethereum Classic came to be after members of the Ethereum community implemented a time-sensitive hard fork ("DAO Hard Fork"). On 20th July 2016, at a block height of 1.92 million, Ethereum introduced an irregular state change via a hard fork in an effort to return approximately 3.6 million ether that had been taken from a smart contract known as The DAO. Almost everyone agreed that the ether taken had been stolen and that leaving it all in the hands of the thief would be of significant detriment to development of the Ethereum ecosystem as well as the platform itself.

Returning the ether to its respective owners before The DAO even existed was technically easy, if rather politically controversial. A number of people in the ecosystem disagreed with this change, believing immutability should be a fundamental principle of the Ethereum blockchain without exception; they elected to continue the original chain under the moniker of Ethereum Classic. While the split itself was initially ideological both chains have since evolved into separate entities.

The Decentralized Autonomous Organization (The DAO)

The DAO was created by Slock.it aiming to provide community-based funding and governance for projects. The core idea was that proposals would be submitted, curators would manage proposals, funds would be raised from investors within the Ethereum community, and if the project proves successful then investors would receive a share of the profits.

The DAO was also one of the first experiments in an Ethereum token. Rather than funding projects directly with Ether, participants would trade their ether for DAO tokens, use them to vote on project funding, and would later be able to trade them back for Ether.

DAO tokens were available to purchase in a crowdsale that ran from 5th April through 30th April 2016, amassing nearly 14% <<[1]>> of the total ether in existence, which was worth ~$150 million USD at the time.

The Re-Entrancy Bug

On 9th June, developers Peter Vessenes and Chriseth reported that most Ethereum-based contracts which manage funds were potentially vulnerable to an exploit <<[2]>> that can empty contract funds. A few days later (12th June) Stephen Tual (Co-founder of Slock.it), reported that The DAO’s code was not vulnerable <<[3]>> to the bug described by Peter and Chriseth. Worried DAO contributors temporarily breathed a sigh of relief until 5 days later, when an unknown attacker ("the DAO Attacker") started draining The DAO <<[4]>> using an exploit similar to the one described on 9th June. Ultimately the DAO Attacker siphoned ~3.6 million ether out of The DAO.

Simultaneously an assemblage of volunteers calling themselves the Robinhood Group (RHG) started using the same exploit to withdraw the remaining funds in order to save them from being stolen by the DAO Attacker. On the 21st June, the RHG announced <<[5]>> that they had secured about 70% of The DAO’s funds (roughly 7.2 million ether), with plans to return it to the community (which they successfully did on the ETC network, and didn’t need to do on the Ethereum network after the fork). Many thanks and commendations are given to the RHG for their quick thinking and fast actions that helped secure the bulk of the community’s ether.

Re-Entrancy Technicals

While a more detailed and thorough explanation of the bug is given by Phil Daian <<[6]>>, the short explanation is that a crucial function in the DAO had two lines of code in the wrong order, meaning that the Attacker could have requests to withdraw ether acted upon repeatedly, before the check of whether the Attacker was entitled to the withdrawal was completed. This type of vulnerability is described in [reentrancy_security].

Re-Entrancy Attack Flow

Imagine you had $100 in your bank account and you could bring your bank teller any number of withdrawal slips. The bank teller gives you money for each slip in order, and only at the end of all the slips do they record your withdrawal. What if you brought them three slips to each withdraw $100? What if you brought them three thousand?

The attack worked like this:

  1. DAO Attacker asks the DAO Contract to withdraw DAO tokens (DAO).

  2. DAO Attacker asks the contract to withdraw DAO again, before the contract updates its records that DAO was withdrawn.

  3. Repeat step two as much as possible.

  4. The contract finally logs a single DAO withdrawal, losing track of the withdrawals that happened in the interim.

The DAO Hard Fork

Fortunately, there were several safeguards built into The DAO: all withdrawal requests were subject to a 28 day delay. This gave the community a little while to discuss what to do about the exploit. From roughly 17th June to 20th July the DAO Attacker would be unable to convert their DAO tokens into Ether.

Several developers focused on finding a viable solution, and multiple avenues were explored in this short space of time. Among them was the DAO Soft Fork, announced on 24th June, to delay DAO withdrawals until consensus was reached <<[7]>>, and a DAO Hard Fork, announced on 15th July, to reverse the effects of the DAO Attack with an exceptional state change <<[8]>>.

On 28th June, developers discovered a DoS exploit in the DAO Soft Fork <<[9]>>, and concluded that the DAO Hard Fork would be the only viable option to fully resolve the situation. The DAO Hard Fork would transfer all ether that had been invested in the DAO into a new refund smart contract, allowing the original owners of the ether to claim a full refund. This provided a solution for returning the hacked funds, but also meant interfering with the balances of specific addresses on the network, however isolated they were. There would also be some leftover ether in portions of The DAO known as childDAOs <<[12]>>. A group of trustees would manually authorize the leftover ether, worth ~$6-7 million at the time <<[8]>>.

With time running out, multiple Ethereum development teams created clients that allowed a user to decide whether they wanted to enable this fork. However, the client creators wanted to decide whether to make this choice opt-in (don’t fork by default), or opt-out (fork by default). On the 15th July, a vote was opened on carbonvote.com <<[10]>>. The next day, at block height 1,894,000 <<[11]>> it was closed. Of the 5.5% of the total ether supply that voted, \~80% of the votes (\~4.5% of the total ether supply) voted for opt-out. One quarter of the opt-out vote came from a single address <<[12]>>.

Ultimately the decision became opt-out, and those who opposed the DAO Hard Fork would need to explicitly state that they opposed by changing a configuration option in the software they were running.

On the 20th July, at block height 1,920,000 <<[13]>> Ethereum implemented the DAO Hard Fork <<[14]>> and thus two Ethereum networks were created, one including the state change, and the other ignoring it.

When the DAO Hard Forked Ethereum (present-day Ethereum) gained a majority of the mining power, many assumed that consensus was achieved and the minority chain would fade away; as in previous forks. Despite this, a sizable portion of the Ethereum community (roughly 10% by value and mining power) started supporting the non-forked chain, which came to be known as Ethereum Classic with the symbol ETC.

Within days, several exchanges began to list both Ethereum ("ETH") and Ethereum Classic ("ETC"). Due to the nature of hard forks, all Ethereum users holding ether at the time of the split then held funds on both of the chains and a market value for ETC was soon established with Poloniex listing ETC on the 24th July <<[15]>>.

Timeline of The DAO Hard Fork

  • 2016 April 5: Slock.it creates The DAO following a security audit by Dejavu Security <<[16]>>

  • 2016 April 30: The DAO crowdsale launches <<[17]>>

  • 2016 May 27: The DAO crowdsale ends

  • 2016 June 9: A generic recursive call bug is discovered and believed to affect many Solidity contracts that track user’s balances <<[2]>>

  • 2016 June 12: Stephen Tual declares that DAO funds are not at risk <<[3]>>

  • 2016 June 17: The DAO is exploited and a variant of the discovered bug (termed the "re-entry bug") is used to start draining the funds; eventually nabbing ~30% of the funds <<[6]>>

  • 2016 June 21: The RHG announces it has secured the other ~70% of the ether stored within The DAO <<[5]>>

  • 2016 June 24: A soft fork vote is announced via opt-in signaling through Geth and Parity clients, designed to temporarily withhold funds until the community can better decide what to do <<[7]>>

  • 2016 June 28: A vulnerability is discovered in the soft fork and it’s abandoned <<[9]>>

  • 2016 June 28 to July 15: Users debate whether or not to hard fork; most of the vocal public debate occurs on the /r/ethereum subreddit

  • 2016 July 15: The DAO Hard Fork is proposed, to return the funds taken in The DAO Attack <<[8]>>

  • 2016 July 15: A vote is held on carbonvote to decide if the DAO Hard Fork is opt-in (don’t fork by default) or opt-out (fork by default) <<[10]>>

  • 2016 July 16: 5.5% of the total ether supply votes, \~80% of the votes (\~4.5% of the total supply) are pro the opt-out hard fork; one quarter of the pro-vote comes from a single address <<[11]>> <<[12]>>

  • 2016 July 20: The hard fork occurs at block 1,920,000 <<[13]>> <<[14]>>

  • 2016 July 20: Those against the DAO Hard Fork continue running the old non-hard fork client software; this leads to issues with transactions being replayed on both chains <<[18]>>

  • 2016 July 24: Poloniex lists the original Ethereum chain under the ticker symbol ETC, the first exchange to do so <<[15]>>

  • 2016 August 10: The RHG transfers 2.9 million of the recovered ETC to Poloniex in order to convert it to ETH on the advice of Bity SA; 14% of the total RHG holdings are converted from ETC to ETH and other cryptocurrencies; Poloniex freezes the other 86% of deposited ETH <<[19]>>

  • 2016 August 30: The frozen funds are sent by Poloniex back to the RHG, which then sets up a refund contract on the ETC chain <<[20]>> <<[21]>>

  • 2016 December 11: IOHK’s ETC development team forms, led by Ethereum founding member Charles Hoskinson

  • 2017 January 13: The ETC network is updated to resolve transaction replay issues; the chains are now functionally separate <<[22]>>

  • 2017 February 20: ETCDEVTeam forms, led by early ETC developer Igor Artamonov (splix)

Ethereum and Ethereum Classic

While the initial split was centered around The DAO, the two networks, Ethereum and Ethereum Classic, are now separate projects, although most development is still done by the Ethereum community and simply ported to Ethereum Classic codebases. Nevertheless, the full set of differences is constantly evolving and too extensive to cover in this chapter. However, it is worth noting that the chains do differ significantly in their core development and community structure.

Technical Differences

The EVM

For the most part (as of April 2018) the two networks remain highly compatible: contract code produced for one chain runs as expected on the other; but there are some small differences in EVM OPCODES (see EIPs 140, 145, and 214).

Core Network Development

Being open projects, blockchain platforms often have many users and contributors. However, the core network development (code that runs the network) is often done by small groups due to the expertise and knowledge required to develop this type of software. As such the code that these groups produce is very closely tied to the code that actually runs the network.

Ethereum Ethereum Classic

Ethereum Foundation, and volunteers.

ETCDEV, IOHK, and volunteers.

thereum_forks]] === A timeline of notable Ethereum forks

Ellaism is an Ethereum-based network, and intends to use exclusively Proof-of-Work to secure the blockchain. It has a zero pre-mine and has no mandatory developer fees, with all support and development donated freely by the community. Its developers believe this makes their coin one of the most honest pure Ethereum projects, and something that is uniquely interesting as a platform for serious developers, educators, and enthusiasts. Ellaism is a pure smart contract platform. Its goal is to create a smart contract platform that is both fair and trustworthy.

Principles:
  1. All changes and upgrades to the protocol should strive to maintain and reinforce these Principles of Ellaism.

  2. Monetary Policy: 280 million coins.

  3. No censorship: Nobody should be able to prevent valid txs from being confirmed.

  4. Open-Source: Ellaism source code should always be open for anyone to read, modify, copy, share.

  5. Permissionless: No arbitrary gatekeepers should ever prevent anybody from being part of the network (user, node, miner, etc).

  6. Pseudonymous: No ID should be required to own, use Ellaism.

  7. Fungible: All coins are equal and should be equally spendable.

  8. Irreversible Transactions: Confirmed blocks should be set in stone. Blockchain History should be immutable.

  9. No Contentious Hard Forks: Never hard fork without consensus from the whole community. Only break the existing consensus when necessary.

  10. Many feature upgrades can be carried out without a hard fork, such as improving the performance of the EVM.

Several other forks have occurred on Ethereum as well. Some of these are hard forks in the sense that they split directly off of the pre-existing Ethereum network. Others are software forks: they use Ethereum’s client/node software but run entirely separate networks without any history shared with Ethereum. There will likely be more forks over the life of Ethereum.

There are also several other projects that claim to be Ethereum forks but are actually based on ERC20 tokens and run on the Ethereum network. Two examples of these are EtherBTC (ETHB) and Ethereum Modification (EMOD). These are not forks in the traditional sense, and may sometimes be called airdrops.

  • Expanse was the first fork of the Ethereum blockchain to gain traction. It was announced via the Bitcoin Talk forum on September 7 2015. The actual fork occurred a week later on September 14 2015 at a block height of 800,000. It was originally founded by Christopher Franko and James Clayton. Their stated vision was to create an advanced chain for: "identity, governance, charity, commerce, and equity".

  • EthereumFog (ETF) was launched on December 14 2017 and forked at a block height of 4,730,660. Their stated aims are to develop "World Decentralized Fog Computing" by focusing on fog computing and decentralized storage. There is still little information on what this will actually entail.

  • EtherZero (ETZ) was launched on January 19 2018 at block height of 4,936,270. Its notable innovations were the introduction of a masternode architecture and the removal of transaction fees for smart contracts to enable a wider diversity of DApps. There have been some criticism from some prominent members of the Ethereum community, MyEtherWallet and MetaMask, due to the lack of clarity surrounding development and some accusations of possible phishing.

  • EtherInc (ETI) was launched on February 13 2018 at a block height of 5,078,585 with a focus on building decentralized organizations. They also announced the reduction of block times, increased miner rewards, the removal of uncle rewards and set a cap on mineable coins. They use the same private keys as Ethereum and have implemented replay protection to protect ether on the original non-forked chain.

References