Introduction to Blockchains
Introduction to Blockchains
Tuesday 1A Convener: Muneeb Ali
Notes-taker(s): Muneeb Ali
Tags for the session - technology discussed/ideas considered:
Discussion notes, key understandings, outstanding questions, observations, and, if appropriate to this discussion: action items, next steps:
Blockchain primer
From Blockstack – Identity on blockchain Define the problem – Decentralized consensus Consensus is hard in computer science – 1000 computers trying to agree on something – e.g., 2 operations over 1000 computers without central controller
Trying to solve simple problem on agreeing on the state of the system
There are different ways to do it. Have nodes – have protocol to establish the leader election – decides what is next action. Protocols can only tolerate certain number of malicious nodes.
Blockchains are another way to do consensus – hard to tamper
Blockchain is a file – can download it – it was 15 gigs, now 45 gigs Presents the genesis block – start of time Time=0 Physical structure of file – time is divided into blocks – genesis block launched in 2008.
Bitcoin blockchain s largest blockchain 0 references here are to bitcoin.
Blocks are written on the blockchain as time passes. Same production network working to produce additional blocks. All data preserved in the blockchain itself. Within each block – have transactions represented.
Now talk about the network If you are a node and want to connect to Blockchain There are two types of nodes – simple node that not want to be a leader (called a miner) Miner is a leader that gets to form the next block.
If not want to participate – just a simple node.
Every node connects on average to 8 other nodes – full broadcast to all other nodes. Full expression of all transactions you hear about to your network.
When new blocks are announced – hear about the new blocks
Nodes that decide to be miners (leader election participants) are trying to solve the hard computer puzzle The puzzle is
- take hash of last block plus some other information and rapidly calculating new hashes
- If the result has a certain number of 00000s in the beginning, Hash is deterministic but completely random.
- After certain amount of tries will get solution with number of zeros.
Miners are in a race to hit the hash that is the solution to the prior block – everyone on the network can verify the success.
The number of 0000 solve for is variable by how much computing power is on the system. If there are more miners, increase the difficulty level.
0000 are just a way to define space.
2 incentives – Miners get the fee that is imposed on the transactions in the block they worked on. 2 – Protocol is used to introduce new currency into the system.
Currency gives the incentives for people to be part of the network. Every new block releases new currency into the system.
New currency is incentive in the front end. Total is 21million bitcoins, so may be self sustaining at that time.
Most important thing to remember – process of doing hard computations – things that were written to the blockchain earlier become more and more security. So attacker seeking to alter transaction written in block 5 blocks old, would need to rewrite the hashes of the past. Problem is that it is computationally intensive.
Once you get 6 levels – probability of rewriting is close to 0. Average is one block every 10-40 minutes. If wait a couple of hours, no one can change the chain.
If changed it – every person would realize it – because would change all history and would see it. [Equivalent of neighborhood watch].
Fork in the network happen, but they are not that deep. If have a deep fork, everyone can want to put a hard stop in the system. Even if attacker is successful, they would have to bring in computational power every time to keep up.
51% issue – Blockchain works as long as no one party has 51 % of the hashing power. Some fraud enabled with 51%. Have 100% transparency on the system also so that helps with neighborhood watch. Forks are indecisions, but they are seen.
What is being done to prevent mining pools getting together and colluding to more than 51%. Theoretically possible, but history suggests that they don’t have the incentive to collude, since it would put their interests at risk [Like Moral hazard – Alan Greenspan expressed surprise that leaders of financial organizations would drive companies into the ground.].
Older thinking was to fork the bitcoin blockchain for other purposes, but now have separate blockchain.
Security is about hashing power and the reliability of the network.
It is all about incentives.
What are consequences of the forks? Usually ignore it, because usually resolved by the 6th block down.
Main blockchain – bitcoin blockchain – can peg other systems on top of it (not forks, but cross reference to other. Bitcoin is solving a very hard problem – once do that, can build on top of that. System that is using a system of functionality can use blockchain.
Longest chain rule – if there is a conflict with blocks mined – the longest chain always wins – since it represents most computational power. Computational sovereignty
In blockstack – information only shows encryption for identity system.
Side chains are different than separate normative cross referenced chains. Are side chains different than forking?
Censorship resistance – principle that everyone is equal – no one can stop it.
No one can stop you from being a node or a miner.
Powerful property – but has complications – people who want to censor.
Also, to have Censorship resistance – also have fungibility – one dime is like any other. Same as bitcoin – how have fungibility.
Censorship resistance is problem when have a concentration of miners – might have 51% group.
What are worse case scenarios that can happen.
If have collusion or state actor interrupting – would hit pause on system. Could go back to see “what block can you trust” and then start a new blockchain from there. Can “re-route” – announce that migrate to other blockchain and migrate other information to a new blockchain. How migrate – Own something with a private key – can migrate it then.
There are different kinds of chains They like idea of single global blockchain.
But there are other models –
e.g., Federated system - can start blockchain with identified parties – 4 parties can decide to have round robin leader election. Still get history, auditability, but don’t get decentralization.
Can have own private space, but not have all the benefits.
Virtual chain – sits on top of other larger chain – normatively cross references it. Certain operations not listed in the main blockchain – introduce new functionality in chain – transactions announced in bitcoin – for servers can construct a
Registration fees for names can be given to miners.
Proof of publication and proof of existence are simplest things to put in first.
Very firm time of when the event happened – can prove it.
Get real history from the proof of existence and proof of publication.
Differences of virtual chains
Blockchain is a state machine – changes state from block to block – put difficult to introduce new functionality. Virtual chain introduces new functionality.
Side chain is just another blockchain. Not branched from the same root, but pegged in some way to the main side chain.
Side chain is one way (or 2 way) pegged. Like currency relationship where currency is convertible to another.
Turning to practice and uses Don’t’ have to trust other parties, can use blockchain and not dependent on another company.
Moves trust out of the network, into the process.
Blockchain allows self sovereign identity.