From DigiByte Wiki
Revision as of 23:50, 26 February 2019 by DigiDevon (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

DigiShield overview

Activated in February 2014, this hard fork allowed for the DigiByte blockchain to protect against multi-pools that mine large numbers of DigiByte at a low difficulty. It achieves this protection by recalculating block difficulty between each block, allowing for a faster correction when a multi-pool begins or ceases contributing to DigiByte, rather than recalculating once every fortnight (2 weeks) as is the case with Bitcoin

Since inception, DigiShield has been added into over 2-dozen other cryptocurrency blockchains such as BitcoinCash, ZCash, Dogecoin, Startcoin, AuroraCoin, BitcoinGold, BitTokens, CasinoCoin, CreativeCoin, Granite, Huncoin, Monacoin, Mooncoin, Nautiluscoin, Quatloo, SakuraCoin, Scorecoin, SmartCoin, StartCoin, SuperiorCoin and Ubiq.

DigiShield has *no* effect on 51% hash-power attack mitigation.

A simple explanation of difficulty retargeting

This is an explanation of difficulty retargeting, knowledge of this is needed in order to understand the value of DigiShield.

In order to maintain an "average" block timing, blockchains such as Bitcoin, Litecoin and DigiByte all use different methods of "difficulty retargeting". The idea being that as there are more miners (Or more specifically, more hash-power provided by the miners) trying to find the next block, it needs to become harder and harder to find the blocks.

DigiByte has a 15-second block timing target, meaning mathematically based on the previous blocks, along with a little bit of chance / randomness, the "difficulty" in finding the cryptographic answer for each block will become harder or easier in order to maintain an approximate 15-second block timing.

Miners will regularly change between the blockchains that they mine, in order to maximize their profits. For example, GPU miners may switch between mining ZCash, Vertcoin and DigiByte, depending on what they are able to mine most profitably at the time. This profitability is determined by the current value of the coin, block rewards (new coins given in a block), block difficulty and block timing.

As more miners begin to mine, they bring their larger amounts of hashing power, and so blocks begin to get found more frequently. As the blocks are found more frequently, the traditional blockchains such as Bitcoin will only adjust the difficulty level every 2016 blocks (Approx every 2 weeks). For Bitcoin, this means that if a large number of miners with their hash power begin instead to mine Bitcoin Cash, the blocks for Bitcoin will slow down and not be found as regularly. Conversely, if miners bring their hash power from Bitcoin Cash to Bitcoin, the blocks will be found a lot faster. Then, every 2016 blocks, the entire blockchain uses some clever mathematics to decide how "difficult" it should be for the next 2016 blocks, based on how fast blocks were found, averaged out over the last 2016 blocks.

For further info on the math behind Difficulty and how it's calculated, see the Bitcoin Wiki

How DigiShield differs & why it matters

DigiShield adjusts after each block, rather than once every 2016 blocks. DigiShield is designed to let the difficulty "fall" very fast, in order that the chain doesn't freeze.

Freezing would occur a lot back in 2014 with the traditional difficulty retargeting system that Bitcoin / Litecoin use, when proof-of-work mining was relatively young. As miners would hop between Litecoin, DigiByte and Dogecoin with their GPU mining (Back when you could mine Scrypt coins on a GPU profitably), DigiByte and Dogecoin especially would end up with a "frozen" chain, where it takes too long to find a block.

It would take too long to find a block, because profit-switching miners would bring their hash power when difficulty was low, they would mine DigiByte for a number of blocks, the difficulty would adjust to account for a 10-fold hash power increase, and then the profit-switching miners stop mining DigiByte (As the profitability has decreased due to the difficulty increase) and they would then move over and start mining Dogecoin.

The difficulty of DigiByte would then be astronomically high, while the amount of miners and hash-power becomes increasingly low, meaning the blockchain could go several hours without a single block being found. Naturally this is highly undesirable, as it could mean waiting for several hours for a transaction to process.

DigiShield was created to account for such wild fluctuations, so that the blockchain doesn't "freeze" when a large exodus of hash power occurs. It also means miners cannot flood a few consecutive blocks with a high amount of hash power and benefit from low difficulty, giving blocks near instantly one after another before traditional difficulty retargeting occurs.

DigiShield was later then implemented in to Dogecoin in early 2014, which at the time was suffering from similar chain-freezing issues as a result of influx and exodus of hash power. The DigiByte developers aided the Dogecoin developers to implement DigiShield, and the result of the change was instantly a success. The benefits seen on DigiByte and subsequently Dogecoin have meant a number of other blockchains have implemented DigiShield, or DigiShield-based algorithms, ranging from Bitcoin Cash, Bitcoin Gold, ZCash and many others.

DigiByte then forked to Multi-Algo (5x mining algorithms) later in 2014, and so DigiShield was not immediately available following this fork, however later DigiByte implemented "MultiShield", a multi-algo specific version of DigiShield.

"MultiShield is the advanced version of the original DigiShield (asymmetric difficulty adjustment now widely implemented in many other blockchains). DigiByte pioneered both MultiShield and DigiShield." -Official DigiByte Website