Let's dive into Blockchain

What’s Blockchain?

To put it bluntly, a chain of blocks made up of data.

  1. A block contains 3 things:
    1. hash
    2. the hash of the previous block
    3. data

Peeling layers of abstractions:

  1. When a block is created its hash is calculated which is unique to each block. If you tamper with a block, it’s hash changes which would make all the following blocks invalid. Also if some data must be changed, you have to create a new block stating the change in the desired block thus leaving a trail, just like a ledger of property. In public records, it is written down who originally owned the land, then who bought it from them and so on.

  2. Now the problem is, computers these days can easily calculate hashes in range of 100k/s, this makes use of hash pretty easy to beat as someone using a fairly powerful machine can just tamper with the block they want to and then recalculate hashes of the entire blockchain too. To mitigate this, blockchain uses a concept called ‘proof of work’.

  3. Proof of Work is a requirement, that expensive computations (mining) must be performed in order to facilitate transactions. Essentially PoW slows down the creation of new blocks. As in the case of bitcoins, each transaction creates a new block and that requires ~10 min of time. Thus if you tamper with one block you will have to perform PoW for all the blocks.

  4. Going back to the concept of ledgers, in the blockchain, there is a single ledger, of which everyone has a copy. Now, who is this everyone? Well, a P2P network is created and every participating member has a copy of the ledger (in case of bitcoin; Merkel trees, a form of data structure are used) and thus everyone can validate the data; leading to a consensus that is ‘trustless’ or that ‘distributes the trust’. In the P2P network , every member is a node. Blocks that are tampered with will be rejected by other nodes. Also, you don’t have an intermediary party (like banks) which all participants trust, but all the participants themselves validate each others’ work and thus trust is distributed. Plus there is no extra cost like banks take a cut when you transfer money from one country to another and speed of transaction is much more (like bitcoin). To realistically compromise a blockchain, you'll have to breach and change a single block, redo PoW for all blocks, take control of at least 50% of P2P network; then only will your tampered block be accepted by the network

  5. An analogy to this distributed trust is a kitty party, wherein a bunch of women gather, put together an amount of money and decide to give all that money to a single member among them. Here they have a consensus and there is no trust (intermediary party like a broker), also the trust is distributed among all participating members.

Questions:

Now all this is fine, but when I stopped and thought about it, a question popped in my mind; isn’t this at the core same as a linked list? The answers aren’t specific but here, take a look:

  1. Answer on Quora
  2. Answer on StackOverflow There is one more thing called smart contract, of which I just heard and will write about next.

References:

  1. keepingstock.net/explaining-blockchain-how-..
  2. youtube.com/watch?v=SSo_EIwHSd4
  3. youtube.com/watch?v=qOVAbKKSH10
  4. youtube.com/watch?v=8fbhI1qVj0c
  5. youtube.com/watch?v=r43LhSUUGTQ
  6. youtube.com/watch?v=XCo6yyutYAM
  7. blockgeeks.com/guides/what-is-blockchain-te..
  8. fool.com/investing/2018/03/18/what-is-block..
  9. investopedia.com/terms/b/blockchain.asp
  10. lifehacker.com/what-is-blockchain-1822094625