Bitcoin Tutorial Joseph Bonneau Princeton University (edited and abridged by Bruce Maggs)

Download Report

Transcript Bitcoin Tutorial Joseph Bonneau Princeton University (edited and abridged by Bruce Maggs)

Bitcoin Tutorial
Joseph Bonneau
Princeton University
Thanks to Andrew Miller, Arvind Narayanan, Jeremy Clark, Joshua Kroll, Ed Felten
(edited and abridged by Bruce Maggs)
Bitcoin Today (October 15, 2014)
One Bitcoin (BTC) is worth about $394.
Every ten minutes, one Bitcoin miner, selected at random, is
given a reward when the block chain is extended by one
block.
In 2009, the reward was 50 BTC. Today it is 25 BTC.
The rewarded miner also receives all (optional) transaction
fees in the block.
bmm
Part I: Bitcoin in 6 easy steps
Double spending: why ecash is hard
SignA(Transfer X to B)
Bob
Redeem X?
BANK
Alice
Redeem X?
SignA(Transfer X to C)
SignZ(Transfer X to A)
Charlie
Step 1: Make the bank a global log
(the block chain)
SignatureBANK
SignatureBANK
...
SignA(Transfer X to B)
SignatureBANK
...
SignA(Transfer X to C)
SignatureBANK
Step 2: Participants vote on blocks
SignatureA SignatureB SignatureC ...
SignatureA SignatureB SignatureC ...
SignatureA SignatureB SignatureD ...
(participants each get one vote, regardless of mining power)
Step 3: A random user picks
N-2
N
SignatureA
N-1
SignatureB
C
N
SignatureC
Step 4: Resolve conflicts by forking
SignatureA
SignatureB
SignA(Transfer X to C)
SignatureC
SignA(Transfer X to B)
SignatureD
SignatureE
Step 5: Incentivise correct blocks
Mint(X, A)
Mint(X, B)
Mint(X, C)
SignatureC
SignatureA
SignatureB
Mint(X, D)
Mint(X, E)
SignatureD
SignatureE
Step 6: Choose by hash power!
Mint(X, A)
Mining difficulty
SHA-256(BlockN-1, n) = 0x00000000000000003f89...
Mint(X, B)
Mining difficulty
SHA-256(BlockN-1, n) = 0x00000000000000008c71...
Mint(X, C)
Preventing double spending
SignA(Transfer X to B)
SignA(Transfer X to C)
Longest chain wins
Transaction confirmation (~6 blocks)
Part II: Mining & Consensus
Checkpointing
How decentralized is Bitcoin?
Mining difficulty
bitcoinwisdom.com
Difficulty adjustment
10 minutes
2 weeks
bitcoinwisdom.com
Mining rewards
Courtesy:
Brian Warner
Total network capacity
● 264 hashes per block (every 10 minutes!)
● 275 hashes in 2013
o In exchange for ~US$250M
● Consuming > 100 MW
Bitcoin mining hardware
Mining pools
Mint(25, KPOOL)
0x00000000000000003f89...
0x000000000000a877902e...
0x0000000000001e8709ce...
0x000000000000490c6b00...
0x00000000000000003f89...
0x00000000000007313f89...
0x00000000000045a1611f...
Mining pools
Part III: Bitcoin as a currency
Why does Bitcoin have value?
Consensus
● Consensus in state (blockchain)
● Consensus in payment
● Consensus in rules
The Economics of Bitcoin Mining, or Bitcoin in the Presence of Adversaries
Joshua Kroll, Ian Davey, Ed Felten. WEIS 2013
Price during 2013
Black Markets
Traveling the Silk Road: A measurement analysis of a large anonymous online marketplace
Nicolas Christin, WWW
2013US$14M in Revenue in 2012 [Christin 2012]
Silk Road:
Capital controls
E-commerce
Bitcoin exchanges
Beware the middleman: Empirical analysis of Bitcoin-exchange risk
Tyler Moore and Nicolas Christin, Financial Crypto 2013
Part IV: Anonymity
Bitcoins carry a transaction history
● identification
● censorship
● recovery from theft
● economic analysis
Towards Risk Scoring of Bitcoin Transactions
Möser, Malte, Rainer Böhme, and Dominic Breuker, BITCOIN 2013
Mixes
Mixes today
Caution: Mixing services may themselves be operating with
anonymity. As such, if the mixing output fails to be delivered
or access to funds is denied there is no recourse. Use at
your own discretion.
-The Bitcoin Wiki
An inquiry into money laundering tools in the Bitcoin ecosystem
Möser, Malte, Rainer Böhme, and Dominic Breuker, ECRIME 2013