Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
TPS&51%Attack
Search
Taiki
June 30, 2018
Research
0
260
TPS&51%Attack
Taiki
June 30, 2018
Tweet
Share
More Decks by Taiki
See All by Taiki
Blenderで作るCG VR
r_etx
1
74
Slush✖️Privacy
r_etx
0
110
WeArelookingForYou.pdf
r_etx
1
680
Zk-SNRAKS1~4
r_etx
0
37
hakone_hackthon
r_etx
0
76
Dynamics of Blockchain
r_etx
1
55
Lightning network
r_etx
0
97
BancorProtocol
r_etx
4
750
GHZstate
r_etx
0
45
Other Decks in Research
See All in Research
Tiaccoon: コンテナネットワークにおいて複数トランスポート方式で統一的なアクセス制御
hiroyaonoe
0
260
한국어 오픈소스 거대 언어 모델의 가능성: 새로운 시대의 언어 이해와 생성
inureyes
PRO
0
150
[依頼講演] 適応的実験計画法に基づく効率的無線システム設計
k_sato
0
220
2024/10/30 産総研AIセミナー発表資料
keisuke198619
1
410
Large Vision Language Model (LVLM) に関する最新知見まとめ (Part 1)
onely7
23
5.4k
非ガウス性と非線形性に基づく統計的因果探索
sshimizu2006
0
480
Whoisの闇
hirachan
3
230
CoRL2024サーベイ
rpc
1
1.3k
KDD論文読み会2024: False Positive in A/B Tests
ryotoitoi
0
270
The Fellowship of Trust in AI
tomzimmermann
0
200
情報処理学会関西支部2024年度定期講演会「自然言語処理と大規模言語モデルの基礎」
ksudoh
10
2.4k
「熊本県内バス・電車無料デー」の振り返りとその後の展開@土木計画学SS:成功失敗事例に学ぶ公共交通運賃設定
trafficbrain
0
120
Featured
See All Featured
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
127
18k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
3.6k
It's Worth the Effort
3n
183
28k
RailsConf 2023
tenderlove
29
970
A Modern Web Designer's Workflow
chriscoyier
693
190k
BBQ
matthewcrist
85
9.4k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
113
50k
How GitHub (no longer) Works
holman
312
140k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
507
140k
Fontdeck: Realign not Redesign
paulrobertlloyd
82
5.3k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
29
960
Docker and Python
trallard
43
3.2k
Transcript
ABOUT TPS & 51% ATTACK CRYPGEEK 30/6/2018 Blockchainษڧձ #10 @r_etx
Proof of WorkͷΈͰɺTPSΛ͍࣋ͬͨ͋͛ͨ
TPSͱɺ
transaction per secͷུͰɺҰඵؒ͋ͨΓʹ͚͞Δ transactionͷྔΛද͢ɻ TPS͕খ͍͞ͱtransaction͕٧·ͬͯঝೝʹ͕͔͔࣌ؒΔɻ VISA 2000TPS( daily peak rate
of 4000 TPS) Pay Pal 115TPS so let’s take 4000 TPS as starting goal!!
transaction per secͷུͰɺҰඵؒ͋ͨΓʹ͚͞Δ transactionͷྔΛද͢ɻ TPS͕খ͍͞ͱtransaction͕٧·ͬͯঝೝʹ͕͔͔࣌ؒΔɻ VISA 2000TPS( daily peak rate
of 4000 TPS) Pay Pal 115TPS BTC 7TPS
transaction per secͷུͰɺҰඵؒ͋ͨΓʹ͚͞Δ transactionͷྔΛද͢ɻ TPS͕খ͍͞ͱtransaction͕٧·ͬͯঝೝʹ͕͔͔࣌ؒΔɻ more over Online game 100000TPS
transaction per secͷུͰɺҰඵؒ͋ͨΓʹ͚͞Δ transactionͷྔΛද͢ɻ TPS͕খ͍͞ͱtransaction͕٧·ͬͯঝೝʹ͕͔͔࣌ؒΔɻ Ωπ͍͡ΌΜ!
Proof of WorkͷΈͰɺTPSΛ͍࣋ͬͨ͋͛ͨ
TPSͷఆࣜԽ TPS(λ, b) = β(λ, b) ⋅ b ⋅ K
K ; 1KB͋ͨΓͷτϥϯβΫΫγϣϯ β ;ϒϩοΫ͕ϝΠϯνΣʔϯʹՃ͞ΕΔׂ߹ b ; ϒϩοΫͷ࠷େऩ༰αΠζ(KB)
TPS(λ, b) = β(λ, b) ⋅ b ⋅ K ҰඵؒͰ͑ΔKB
1/KB ͋ͨΓͷTx K ; 1KB͋ͨΓͷτϥϯβΫΫγϣϯ β ;ϒϩοΫ͕ϝΠϯνΣʔϯʹՃ͞ΕΔׂ߹ b ; ϒϩοΫͷ࠷େऩ༰αΠζ(KB) TPSͷఆࣜԽ
TPS(λ, b) = β(λ, b) ⋅ b ⋅ K ҰඵؒͰ͑ΔKB
1/KB ͋ͨΓͷTx TPSͷఆࣜԽ β ɺɹ ͷؔɻ ͱɹ ͷҧ͍? β λ λ
ωοτϫʔΫͰ৽͍͠Block͕ੜ͞ΕΔ·Ͱ ฏۉ10(=600[s])ʹͳΔΑ͏ʹઃఆ͞Ε͍ͯΔɻ λ ; Block Treeʹblock͕Ճ͞ΕΔׂ߹ ϒϩοΫ͕ٿ্Ͱڞ༗͞ΕΔͷʹ͔͔Δ࣌ؒΑΓ ৽͍͠Block͕ੜ͞ΕΔ·Ͱͷ͔͔Δ ฏۉͷ͕࣌ؒ͘ͳΔΑ͏ʹઃఆ͞Ε͍ͯΔɻ BitcoinͰɺ
λ = 1 600
ωοτϫʔΫͰ৽͍͠Block͕ੜ͞ΕΔ·Ͱ ฏۉ10(=600[s])ʹͳΔΑ͏ʹઃఆ͞Ε͍ͯΔɻ λ = 1 600 β ;ϒϩοΫ͕ϝΠϯνΣʔϯʹՃ͞ΕΔׂ߹ (Networkʹ͓͚ΔԆForkΛߟྀ͍ͯ͠Δ) λ
; Block Treeʹblock͕Ճ͞ΕΔׂ߹
ωοτϫʔΫͰ৽͍͠Block͕ੜ͞ΕΔ·Ͱ ฏۉ10(=600[s])ʹͳΔΑ͏ʹઃఆ͞Ε͍ͯΔɻ λ ; Block Treeʹblock͕Ճ͞ΕΔׂ߹ BitcoinͰɺ λ = 1
600 β ;ϒϩοΫ͕ϝΠϯνΣʔϯʹՃ͞ΕΔׂ߹ (NetworkͰͷԆؚΜͰ͍Δ) β(λ, b)
0OFNPSF
Topology of network
Topology of network ࠓճߟ͑ͳ͍ɻ
TPSͷఆࣜԽ TPS(λ, b) = β(λ, b) ⋅ b ⋅ K
TPSΛ૿͔ͨͬͨ͠Βɺࡾͭͷํ๏͕͋Δ ҰඵؒͰ͑ΔKB 1/KB ͋ͨΓͷTx K ; 1KB͋ͨΓͷτϥϯβΫΫγϣϯΛ૿͢ β ;ϒϩοΫ͕ϝΠϯνΣʔϯʹՃ͞ΕΔׂ߹Λ૿͢ b ; ϒϩοΫͷ࠷େऩ༰αΠζ(KB)Λ૿͢
Txͷ༰ྔΛখ͘͢͞Δɻ SegwitͳͲ K ; 1KB͋ͨΓͷτϥϯβΫΫγϣϯΛ૿͢ β ;ϒϩοΫ͕ϝΠϯνΣʔϯʹՃ͞ΕΔׂ߹Λ૿͢ b ; ϒϩοΫͷ࠷େऩ༰αΠζ(KB)Λ૿͢
Big Block Bitcoin CashͳͲͰ࠾༻ K ; 1KB͋ͨΓͷτϥϯβΫΫγϣϯΛ૿͢ β ;ϒϩοΫ͕ϝΠϯνΣʔϯʹՃ͞ΕΔׂ߹Λ૿͢ b
; ϒϩοΫͷ࠷େऩ༰αΠζ(KB)Λ૿͢
10ؒʹҰͰͳ͘ɺ ͬͱ͍࣌ؒʹBlock͕ੜ͞ΕΔΑ͏ʹ͢Δ K ; 1KB͋ͨΓͷτϥϯβΫΫγϣϯΛ૿͢ β ;ϒϩοΫ͕ϝΠϯνΣʔϯʹՃ͞ΕΔׂ߹Λ૿͢ b ; ϒϩοΫͷ࠷େऩ༰αΠζ(KB)Λ૿͢
K ; 1KB͋ͨΓͷτϥϯβΫΫγϣϯΛ૿͢ β ;ϒϩοΫ͕ϝΠϯνΣʔϯʹՃ͞ΕΔׂ߹Λ૿͢ b ; ϒϩοΫͷ࠷େऩ༰αΠζ(KB)Λ૿͢ 5ISPVHIQVU 514
#MPDLTJ[F C #MPDLSBUF Е 'PSLJO #MPDL5SFF 4FDVSJUZ ЌЕ
K ; 1KB͋ͨΓͷτϥϯβΫΫγϣϯΛ૿͢ β ;ϒϩοΫ͕ϝΠϯνΣʔϯʹՃ͞ΕΔׂ߹Λ૿͢ b ; ϒϩοΫͷ࠷େऩ༰αΠζ(KB)Λ૿͢ ͲͪΒͷ߹ɺϑΥʔΫ͕ى͖͘͢ͳΓ ҆શੑ͕Լ͢Δɻ(51%
Atttackʹऑ͘ͳΔ)
51% Attack
Security Attacker͕ɺHonest nodeͷ computational power ͷ q ͷׂ߹ʹ૬͢Δcomputational power Λ͍࣋ͬͯΔͱ͢Δɻ
λh β(λh , b) > qλh AttackerͷBlock Creation rate honest nodeͷmain chain creation rate Ͱ͋Ε҆શɻ
Larger Blocks Blockͷେ͖͕͞૿͑Δͱɺάϥϑʹࣔ͢Α͏ʹɺ Ԇ͕࣌ؒ૿Ճ͢ΔɻͦͷͨΊɺ৽͍͠Bock͕ੜ͞Εͨnode ͔ΒΕͨnodeͷup date͕͘ͳΔɻ β(λh , b) >
qλh Easy to attack β become smaller
Acceleration Block Creation Blockͷੜ͕༰қʹͳΓɺ৽͘͠ݟ͔ͭͬͨBlock͕ ൖͯ͘͠ΔΑΓલʹɺઌʹࣗͷnodeͰBlock͕ੜ͞ΕΔ Honest nodeඇޮʹɺAttackerޮతʹϚΠχϯάͰ͖Δ β(λh , b)
> qλh Easy to attack qλh become bigger
Using a GHOST GHOSTΛ༻͍Δ͜ͱʹΑͬͯɺForkͷͨ͠ ແବʹͳΒͣSecurityʹߟྀ͞ΕΔɻ β(λh , b) > qλh
λh > qλh
Using a GHOST β(λh , b) > qλh λh >
qλh 1 > q GHOSTΛ༻͍Δ͜ͱʹΑͬͯɺForkͷͨ͠ ແବʹͳΒͣSecurityʹߟྀ͞ΕΔɻHonest node ͱಉ͡ computational power ͕ͳ͍ͱ߈ܸ͕ޭ͠ͳ͍!!
Using a GHOST β(λh , b) > qλh λh >
qλh 1 > q Block creation rateΛ͋͛ΒΕΔɻ Block sizeΛ͋͛ΒΕΔɻ
͓·͚
BobɺAlice͔Β͓ՖΛങͬͯࢧ͓ͬͨۚΛୣ͍͍ͨɻ ͋Δ࣌ࠁtʹൃߦͨ͠txʹରͯ͠ɺTඵਐΜͩ࣌ࠁt+Tʹɺͦͷtxؚ͕·ΕΔ ϒϩοΫ͔Β͞Βʹ3ݸͷϒϩοΫ͕ঝೝ͞ΕͨͷΛ֬ೝ͠ɺAliceɺBobʹ ͓ՖΛൃૹͨ͠ɻ ͜ͷঢ়گͰɺAlice͕Bob͔Βٗʹ߹͏֬ΛٻΊΑɻ ͨͩ͠ɺBobminerͰcomputational powerΛ 100͍࣋ͬͯΔɻ ͦΕҎ֎ͷਖ਼ͳminer͕͍࣋ͬͯΔ Computational
power ͕ 300Ͱ͋Δͱ͢Δɻ
લఏʀ"UUBDLFS"MJDF͕ՖΛૹΔ·ͰӅΕͯ#MPDLΛੜ͢Δɻ BUUBDLFSͷDPNQVUBUJPOBMQPXFSɺIPOFTUOPEFͷ )POFTUOPEFɺ"MJDF͕ՖΛૹΔ·Ͱʹ#MPDLੜͨ͠ɻ ͜ͷͱ͖ɺ"UUBDLFSOPEFͰɺ"MJDF͕ՖΛૹΔ·ͰʹLCMPDLੜ͢Δ֬ɺ QPJTTPOͰܭࢉͰ͖ͯɺ P(k) = λke−λ k! ͜͜Ͱɺ"UUBDLFSͰͷ#MPDLੜͷׂ߹ͷฏۉɹɹɺ
λ λ = 3 × 1 3 = 1
Lͷ߹ɺӅΕͯੜ͍ͯͨ͠#MPDL͕NBJODIBJOͱͯ͠࠾༻͞ΕΔɻ ҰํɺӅΕͯੜ͍ͯͨ͠DIBJO͕Lͷ࣌ɺ͞Βʹ#MPDLੜ͕ඞཁɻ ͕ͨͬͯ͠ɺ߈ܸ͕ޭ͢Δ֬ɺ P = ∞ ∑ k=0 λke−λ k!
× ( 1 3 ) 3−k JGL JGL 1 = 0.19597 Ͱޭ͢Δɻ ݁ߏͰ͔͍ "UUBDLFSɺ͜ͷ߈ܸͰಘΒΕΔϝϦοτͱ௨ৗͷOPEFͱͯ͠ NJOJOHใुͷϝϦοτΛൺֱͯ͠߹ཧతͳஅΛ͢Δɻ
BobɺAlice͔Β͓ՖΛങͬͯࢧ͓ͬͨۚΛୣ͍͍ͨɻ ͋Δ࣌ࠁtʹൃߦͨ͠txʹରͯ͠ɺTඵਐΜͩ࣌ࠁt+Tʹɺͦͷtxؚ͕·ΕΔ ϒϩοΫ͔Β͞Βʹ3ݸͷϒϩοΫ͕ঝೝ͞ΕͨͷΛ֬ೝ͠ɺAliceɺBobʹ ͓ՖΛൃૹͨ͠ɻ ͜ͷঢ়گͰɺAlice͕Bob͔Βٗʹ߹͏֬ΛٻΊΑɻ ͨͩ͠ɺBobminerͰcomputational powerΛ 100͍࣋ͬͯΔɻ ͦΕҎ֎ͷਖ਼ͳminer͕͍࣋ͬͯΔ Computational
power ͕ 300Ͱ͋Δͱ͢Δɻ
https://eprint.iacr.org/2013/881.pdf Reference https://bitcoin.org/bitcoin.pdf [1] [2]