One of crypto’s most feared attacks may have an elegant solution.
At least, that’s according to the team behind cryptocurrency project Horizen – formerly zencash – which saw more than $500,000 hacked from an exchange in such an attack, called a 51 percent attack, earlier this year.
This attack happens when one single malicious miner controls more than 51 percent of the compute power on a blockchain network and can then inject false transactions into the system.
In a paper released today, the Horizen team claim to have found an innovative solution – by updating their proof-of-work consensus algorithm with a so-called “delay function” that penalizes miners that could be preparing for such an attack. Horizen is a fork of privacy-oriented crypto zcash, which is itself a fork of bitcoin.
Because a 51 percent attack requires a miner to produce blocks in secret before posting them to the blockchain, co-founder of Horizen Rob Viglione said a delay function allows for penalties that make such attacks prohibitively expensive.
“So what it does is essentially it poses a massive cost, a 10x cost, on trying to launch one of these attacks,” he told CoinDesk.
Stepping back, the 51 percent attack has been a part of many crypto enthusiast’s awareness this year, after five major cryptocurrencies lost money due to the attack in June.
Because they damage the confidence in the security of cryptocurrencies more broadly, Viglione described such attacks as a “negative externality on the entire industry.”
And with direct insight into the attack – the 51 percent attack on Horizen resulted in 36 fake blocks being included in the blockchain – Viglione said:
“Right after the attack our engineers started brainstorming and we think we have a very elegant, simple solution to make sure that this doesn’t happen again.”
He continued, “Technically, to make it costly if it were ever to happen again.”
To do this, Horizen’s new algorithm introduces penalties for delayed blocks – those that are broadcast to the network a long time after the latest block.
In effect, the new code release modifies a feature of the underlying consensus algorithm, the so-called “longest chain rule,” with a delay function.
For example, if a block is proposed that is 5 blocks or more behind the most recent, a penalty is introduced, Viglione said. That quadratically increases the amount of blocks a miner needs to produce in order to have transactions accepted onto the chain, he continued.
As such, the chances of a 51 percent attack are decreased.
And because of the nature of Horizen’s architecture, such a penalty should only occur if the miner is malicious, Viglione said.
“We have an average block find time of 2 and a half minutes, maximum latency to broadcast anywhere in the world is like one or two seconds, so there’s no way you could be 5 blocks behind legitimately,” he explained.
This though, Viglione noted, could cause a network partition to occur on the blockchain, as multiple chains of blocks compete to be recognized as the honest chain. In this case, Viglione said miners will vote to determine which chain is legit.
“They essentially elect which chain is legitimate and they start mining on that just like they would any longest chain rule,” Viglione said.
Additionally, to prevent such network splits from being permanent, Viglione said that penalties decrease on the accepted chain.
“Blocks are added and there’s a negative one decrement to the penalty that was previously assessed, so there’s always a convergence that can happen to prevent the network partition being permanent,” he told CoinDesk.
An age old question
Accompanying the release, a white paper states that should a chain of blocks be rejected due to being too far behind the most recent block, exchanges can freeze suspicious deposits until the situation is resolved.
Additionally, Viglione said the specifics of the penalties can be tweaked depending on network conditions.
“We can tune and dial up the cost if we ever think it’s insufficient relative to hashrates and all that,” he told CoinDesk.
Still, it’s worth noting that such changes have long been the subject of research, and others are skeptical about whether Horizen can achieve its claims.
For example, leading ethereum proof-of-stake researcher Vlad Zamfir noted that while he had yet to dig into Horizen’s new code, “the design space doesn’t include miracles.”
Additionally, consensus researcher Emin Gur Sirer expressed skepticism, telling CoinDesk, “these protocols are subtle and difficult to get right.”
But, following several months of testing, Viglione is confident that the new algorithm works well in practice, and hopes it can set an example for the broader cryptocurrency industry.
“We’ve been testing it internally for a little while now, a couple of months, so we’re pretty confident with the code,” Viglione said, adding:
“I’d imagine that other projects should, they really should update their code as well.”
EDIT (16.20 UTC October 10 2018): This article has been updated to reflect that the victim of Horizen’s June 51 percent attack was a cryptocurrency exchange, not Horizen itself.
Cut wire image via Shutterstock
Credit: Source link