Featured

Blockchain Series: 01- Blockchain 101

Since the evolution of WWW (World Wide Web), all the communications was thru servers. Any application on WWW should be deployed to single/multiple servers. And whenever to access it you, you do thru it.
This model worked fine since the WWW was still emerging. But after a while, and specially after the we development has advanced, people discovered that WWW model is not the best. Especially on the security area, where any site following that model can be penetrated, however, still there will be difficulty especially if your site is running behind a giant network.

www

To overcome this issue, Peer-to-Peer technology was initiated. As its name state, the communication will be done directly from peer-to-peer without any mediation. One of the 1st application on this area was “Napster” which allows peers in network to exchange songs. Then the Torrent applications dominated the world (regardless about it’s legality!!).

PeerToPeer

After that Blockchain was poped out to surface.

The term Blockchain was coined by Satoshi Nakamoto, who published the white paper “A Peer-To-Peer Electronic Cash System” in 2008. This article was the foundation in which Blockchain technology was built on.

Bitcoin was the first Blockchain application. It’s considered the 1s digital currency. In Bitcoin, the “Coin” is the basic valuable asset. Coin is not represented in any physical form i.e Dollar, Euros. However, coin is attached to identity and owner. Owner can spend the coin by transferring (paying) other peer in network.

The most important concepts the Bitcoin was trying to achieve is that the governments and banks are no longer the community controls. It’s simply the holders and receivers of coins who are in charge. So the transaction time which take approximately 3-4 days which done by banks today, will take a seconds in Bitcoin era. Of course there is a lot of complicated algorithms and mathematics which made such thing possible, however, I will leave Bitcoin for another blog and keep focusing on Ethereum platform.
For more information about Blockchain innovation journe, check this link.

What is Blockchain?

Blockchain is a Decentralized system for exchange of value with the following characteristics:

  • Uses a shared distributed ledger
  • Transaction immutability achieved by way of blocks & chaining
  • Leverages consensus mechanism for validating the transactions
  • Uses cryptography for trust, accountability, securityIn the upcoming section I will drill down through each characteristic.

Shared Distributed Ledger

A distributed ledger can be described as a ledger of any transactions or contracts maintained in decentralized form across different locations and people (nodes), eliminating the need of a central authority to keep a check against manipulation.
That is, every single node on the network processes every transaction, coming to its own conclusions and then voting on those conclusions to make certain the majority agree with the conclusions. It called consensus

The invention of distributed ledgers represents a revolution in how information is gathered and communicated. Distributed ledgers allow users to move beyond the simple centric database and the effort to how we use, manipulate and extract value from it — to system of records linked (chained) to each other.

dis

Immutability and Blocks Chaining

It means that data added to the ledger CANNOT be Updated or Deleted. This way, the consumer of Blockchain data will have the confidentiality that data has not been altered.
To achieve immutability, Blockchain uses Hasing technique heavily. The block is being created for each transaction. Each block consist of following info:

  • Index: incremental number identify block location
  • Timestamp: block creation date and time
  • Hash: the hash of the block to be added. This will be used later to prevent block data from being tempered.
  • PreviousHash: This will store the hash of previous link. However, for block  (Genesis block) the value will be 0 since there is no previous block exist.
  • Block Data (Transactions): this will field will be used to store data to be persisted. The data field is different from one platform to another. For instance, in Bitcoin, data field will store amount info, sender and receiver address. In Ethereum, we have the flexibility to store any other data.

Consensus

Consensus is ensure the data consistency across the network. It’s a protocol by which peers agree on state of ledger.
It ensures that all peers in the network has exactly the same copy of ledger.
Fraudulent transactions kept of the ledger.
It guarantees to record transaction in chronological order.

Bitcoin is using Proof of Work (POF) methods.
Ethereum is using also POF. However, it’s expected to change in next update to be Proof of Authority (POA).

Conclusion

In this blog, we touched the surface of Blockchain. We learned the history of it. Then we learned how it works and what the main characteristics of it.

In the next blog, I will dig deep into Ethereum platform.

See you…

 

Git – Syncing a fork

This is to describe how to Sync a fork of a repository to keep it up-to-date with the upstream repository.

Note: before cont. make sure that your fork is pointing to the upstream repo. as descriped here.

Sync steps:

  1. Open Git Bash
  2. Change the current working directory to your local project.
  3. Fetch the branches and their respective commits from the upstream repository. Commits to master will be stored in a local branch, upstream/master.

    git fetch upstream

  4. Check out your fork’s local master branch.

    git checkout master

  5. Merge the changes from upstream/master into your local master branch. This brings your fork’s master branch into sync with the upstream repository, without losing your local changes.

    git merge upstream/master

For a reference, check the original steps from Github

 

Blockchain: Understand the basics

Since the Blockchain is considered now as one of the hottest emerging technologies, and until now everyone has a different understating to it, I said to myself I will try reflect my understanding to it.

So after I attended a bootcamp  that covers Blockchain and Ethereum extensively, I came out with a conclusion that this technology is going to change the world and how business is being done. Although until now it’s has not been deployed to a real production case, however, I belive that every IT should invest of him/her self to digest and fully comprehend the idea of it. 

So, this is my shoot trying to share my experience on Blockchain hoping that someone will find it useful. I will try to cover different aspects of the Blockchain platform. I will cover the theory part, then I will move to the part I love, DEVELOPMENT. 
I will pick Ethereum as my flavour for a different reasons that I will cover it later in upcoming posts. Also, I’m going to cover a bunch of tools that will be used in developement i.e MetaMask, TruffleGanache, and many other tools.

Below is the link for blog series. Note that the links will be modified as I’m adding new blogs.

Happy Blockchain journey 🙂

 

Design a site like this with WordPress.com
Get started