attacks on mining protocol
play

Attacks on Mining Protocol Yujin Kwon KAIST 2018.03.22 1 - PowerPoint PPT Presentation

Attacks on Mining Protocol Yujin Kwon KAIST 2018.03.22 1 Cryptocurrencies Cryptocurrencies Increa rease! se! Cryptocurrencies Increa rease! se! 1 BTC $8.5K 1 ETH $180 Proof-of-Work Mining They use blockcha kchain to run


  1. Attacks on Mining Protocol Yujin Kwon KAIST 2018.03.22 1

  2. Cryptocurrencies

  3. Cryptocurrencies Increa rease! se!

  4. Cryptocurrencies Increa rease! se! 1 BTC ≈ $8.5K 1 ETH ≈ $180

  5. Proof-of-Work Mining  They use blockcha kchain to run without a trusted third party.  Miners generate blocks by spending their comp mputatio utationa nal power er.  If a miner generates a valid block, he earns re rewar ard d for t r the block.  This process is competi etiti tive ve. 12.5 5 BTC (N (N-1) 1)-th th Block New Block ock N-th th Bloc ock k (N+1)-th th Block Block ockch chain ain Miner ner

  6. Proof-of-Work Mining  Problem Nonce – Miners must solve cryptographic problems to generate a valid block. – What is the valid nonce such that 𝐼(𝑑𝑝𝑜𝑢𝑓𝑜𝑢𝑡| 𝑜𝑝𝑜𝑑𝑓 < TARGET 𝐺 ? – 𝐼(∙) is a hash function based on SHA-256 in Bitcoin.

  7. Step (Miner)  New transactions are broadcast to all nodes.  Each node collects new transactions into a block.  Each node works on finding a difficult proof-of-work for its block.  When a node finds a proof-of-work, it broadcasts the block to all nodes.  Nodes express their acceptance of the block by working on creating the next chain, using the hash of the accepted block as the previous hash.

  8. Forks

  9. Forks

  10. Forks

  11. Forks

  12. Forks

  13. Forks  Only one head is accepted as a valid one among heads.  An attacker can generate forks intentionally by holding his found block for a while.

  14. Forks  Only one head is accepted as a valid one among heads.  An attacker can generate forks intentionally by holding his found block for a while.

  15. Mining Difficulty Inc ncrease! rease! iculty ulty Diffic Di Ti Time From “https://blockchain.info”

  16. Mining Pool Others rs 8% 8% Others rs Litecoi oin AntPool ol Others rs Ethpool ool 21% 21% 6% 6% 23% 23% 23% 23% AntPool ol 27% 27% BW.COM COM 30% 30% 6% 6% Ethfans ans ViaBTC BTC.COM C.COM 8% 8% 10% 10% F2Pool 7% 7% 11% 11% BW.COM COM LTC.top MPH F2Pool 7% 7% 10% 10% 10% 10% BitFury 23% 23% F2Pool nano Slush 11% 11% BTCC 30% 30% 11% 11% 7% 7% 11% 11% Ethereum Litecoin Bitcoin  Miners organize pools and prefer to mine together to reduce the variance of reward.  Currently, major players are pools.

  17. Mining Pool Pool manager 1. Give the problem. PPoW: 𝐼(𝑑𝑝𝑜𝑢𝑓𝑜𝑢𝑡| 𝑜𝑝𝑜𝑑𝑓 < target 𝑄 ? FPoW: 𝐼(𝑑𝑝𝑜𝑢𝑓𝑜𝑢𝑡| 𝑜𝑝𝑜𝑑𝑓 < TARGET 𝐺 ? (target 𝑄 ≫ TARGET 𝐺 ) Workers

  18. Mining Pool PPoW 463 125 Pool manager 352 432 FPoW 2. Submit shares. Workers

  19. Mining Pool Pool manager 3. Pay the reward. Workers

  20. Several Mining Attacks  The 51 % Attack  “The Economics of Bitcoin Mining, or Bitcoin in the Presence of Adversaries”, WEIS 2013  Selfish mining – Generate forks intentionally  “Majority Is Not Enough: Bitcoin Mining Is Vulnerable”, FC 2014  Block withholding (BWH) attack – Exploit the pools’ protocol  “The Miner’s Dilemma”, IEEE S&P 2015  “On Power Splitting Games in Distributed Computation: The Case of Bitcoin Pooled Mining”, CSF 2016  Fork after withholding (FAW) attack – Generate forks intentionally through pools  “Be Selfish and Avoid Dilemmas: Fork After Withholding (FAW) Attacks on Bitcoin ”, ACM CCS 2017

  21. Selfish Mining 21

  22. Selfish Mining  Forks – Due to the nonzero block propagation delay, nodes can have different views. – When a fork occurs, only one block becomes valid. Which of two blocks should I choose as a main (N+1)-th th Bl Block chain? N-th th Bloc ock k (N-1) (N 1)-th th Block (N+1)-th th Block Fork

  23. Selfish Mining  Generate intentional forks adaptively. – An attacker finds a valid block and propagates the block when en anot other her bloc ock k is found d by an honest est node.  Force the honest miners into wasting victims’ computations on the stale public branch.

  24. Selfish Mining  𝛿: An attacker’s network capability  When an attacker possesses more than 33% computational power, the attacker can always earn extra rewards.

  25. Selfish Mining

  26. Selfish Mining Im Impra practical! ctical!

  27. Impractical  The value of γ cannot be 1 because when the intentional fork occurs, the honest miner who generated a block will select his block, not that of the selfish miner.  Honest miners can easily detect that their pool manager is a selfish mining attacker. – If the manager does not propagate blocks immediately when honest miners generate FPoWs, the honest miners will know that their pool manager is an attacker. – The blockchain has an abnormal shape when a selfish miner exists.

  28. Block Withholding Attack 28

  29. Block Withholding (BWH) Attack 463 125 Pool manager 352 432 Withhold Submit only PPoWs. An Attacker

  30. Block Withholding (BWH) Attack  An attacker joins the victim pool.  She should split her computational power into solo mining and malicious pool mining (BWH attack).  She receives unearned wages while only pretending to contribute work to the pool. Solo Pool Pool BWH Attack Mining Attacker

  31. Block Withholding (BWH) Attack

  32. Result Infiltration mining power Attacker relative reward Victim relative reward  The BWH attack is always profitable.

  33. The Miners’ dilemma (S&P 2015)  Pools can launch the BWH attack each other through infiltration. Infiltration from Pool 1 into Pool 2 Po Pool ol 1 Po Pool ol 2 Infiltration from Pool 2 into Pool 1

  34. Result  When they execute the BWH attack each other, both of them make a loss.

  35. The Miners’ dilemma (S&P 2015) From “The Miner’s Dilemma”  The equilibrium reward of the pool is inferi nferior or compared to the no-attack scenario.  The fact that the BWH attack is not ot co commo mmon n may be explained.

  36. Fork After Withholding Attack 36

  37. FAW Attack Against One Pool Submit an FPoW to the pool only Tar arge get t poo ool if others generate another block. Otherwise, throw away her FPoW. Pool Pool Solo Mining Attacker Others rs

  38. FAW Attack Against One Pool Submit an FPoW to the pool only Tar arge get t poo ool if others generate another block. Otherwise, throw away her FPoW. Pool Pool Solo Mining Attacker Others rs  An attacker generates forks intentionally through a pool!

  39. FAW vs BWH Case 1) When an attacker finds an FPoW through solo mining… FAW/ W/ BWH Attack acker er (N (N-1) 1)-th th Block New Block ock N-th th Bloc ock k (N+1)-th th Block Blockch ockchain ain Victim ctim Othe hers rs

  40. FAW vs BWH Case 1) When an attacker finds an FPoW through solo mining… FAW/ W/ BWH Attack acker er (N (N-1) 1)-th th Block New Block ock N-th th Bloc ock k (N+1)-th th Block Blockch ockchain ain The attacker earns the block reward. Victim ctim Othe hers rs

  41. FAW vs BWH Case 2) When an honest miner in the victim pool finds an FPoW … FAW/ W/ BWH Attack acker er (N (N-1) 1)-th th Block New Block ock N-th th Bloc ock k (N+1)-th th Block Blockch ockchain ain Victim ctim Othe hers rs

  42. FAW vs BWH Case 2) When an honest miner in the victim pool finds an FPoW … FAW/ W/ BWH Attack acker er (N (N-1) 1)-th th Block New Block ock N-th th Bloc ock k (N+1)-th th Block Blockch ockchain ain The victim earns the block reward and shares the reward with the attacker. Victim ctim Othe hers rs

  43. FAW vs BWH Case 3) When only others find an FPoW … FAW/ W/ BWH Attack acker er (N (N-1) 1)-th th Block New Block ock N-th th Bloc ock k (N+1)-th th Block Blockch ockchain ain Victim ctim Othe hers rs

  44. FAW vs BWH Case 3) When only others find an FPoW … FAW/ W/ BWH Attack acker er (N (N-1) 1)-th th Block New Block ock N-th th Bloc ock k (N+1)-th th Block Blockch ockchain ain Others earn the block reward. Victim ctim Othe hers rs

  45. FAW vs BWH Case 4) When the attacker finds an FPoW in the victim pool, BWH and others also find another FPoW … Attack acker er (N (N-1) 1)-th th Block New Block ock N-th th Bloc ock k (N+1)-th th Block Blockch ockchain ain Victim ctim Othe hers rs

  46. FAW vs BWH Case 4) When the attacker finds an FPoW in the victim pool, BWH and others also find another FPoW … Attack acker er (N (N-1) 1)-th th Block New Block ock N-th th Bloc ock k (N+1)-th th Block Blockch ockchain ain Others earn the block reward. Victim ctim Othe hers rs

  47. FAW vs BWH Case 4) When the attacker finds an FPoW in the victim pool, FAW and others also find another FPoW … Attack acker er Attacker’s Ne New Block ock (N (N-1) 1)-th th Block N-th th Bloc ock k (N+1)-th th Block Others’ Blockch ockchain ain Ne New Block ock Victim ctim Othe hers rs

Recommend


More recommend