Lecture 2 - Mining Flashcards
Why do we need blockchain?
To prevent double spending
–> have an ordered list of all transactions; public
What is a sybil attack?
A Sybil Attack refers to when a system is violated by an entity that controls two or more different identities in a network.
–> Voting does not work
How do we solve the Sybil problem?
Make people pay for each vote. –> Proof of Work
polynomial time
An algorithm is polynomial (has polynomial running time) if for some 𝑘,𝐶>0, its running time on inputs of size 𝑛 is at most 𝐶𝑛𝑘. Equivalently, an algorithm is polynomial if for some 𝑘>0, its running time on inputs of size 𝑛 is 𝑂(𝑛𝑘). This includes linear, quadratic, cubic and more. On the other hand, algorithms with exponential running times are not polynomial.
What are the assumptions of a fair coin issuance?
- Start with zero coins in the system
- reward voters with freshly generated coins for supporting the network
- reduce issuance over time to approach a fixed maximum (period halvings)
current estimated total hashrate
213 EH/s
How often is the difficulty adjusted?
Every 2016 blocks
How do we calculate the new difficulty?
New difficulty = current difficulty / (time taken for last 2016 blocks / 2 weeks)
Could quantum computers find valid block hashes easily?
No. Because Bitcoin uses two SHA-256 sequentially.
Could a quantum computer crack Bitcoin wallets and steal the coins?
- Very old addresses (P2PK) use the plain public key so they are attackable via Shor’s algorithm.
- Other addresses that have never been used to send funds: addresses are themselves hashes and since breaking a hash is not feasible they are safe.
- Any addresses that have send any number of coins in the past: Sending coins requires to sign a transaction. This exposes the private key, so we are vulnerable to Shor
Shor’s algorithm
can factor large numbers in O(log(n)) instead of O(n)
Grover’s algorithm
can crack hashes O(sqrt(n)) instead of O(n)
What to do against quantum attacks?
Never reuse Bitcoin addresses.
What are mining pools?
Miners construct blocks at a lower difficulty and submit those as proof of work. When one miner actually finds a block, the hashrate statistics of all miners on the pool are used to calculate fair payouts.
Pros of a mining pool
- miners get consistent rewards
- miners don’t need to run a node