A journey to full stack programming

This is my other journey on getting my hands with programming. This time, trying to learn full stack programming using javascript; node.js, react-native, socket-io, etc.

Smartphone

独家优惠奖金 100% 高达 1 BTC + 180 免费旋转




Entering the Blockchain

Blockchain is the most current, high-voltage, talked-about tech of the world! May be so due to the huge economic and financial tag that comes with it. Interestingly though, one of the things that we learnt early on in the session was…there is much more than just a financial outcome off this technology. While training sessions always get an eager, ‘would-love-to’ reaction from all Synsoftians, Blockchain takes the cake and tops all sessions this year, in every way!

As critical as it might be, to upgrade the strength of a team regularly, what is difficult to know is the next new big thing, in the tech world!

Highlights of the Blockchain Technology

It started with an online session from Udemy which was an eye-opener on various nitty-gritty’s surrounding the blockchain concept. With Blockchain it was a given, that there was immense potential and it fit well into the general course of the organization. So, our next step was a 4-day long session that would take us deeper into Blockchain, conceptually and technically.

The session helped us to visualize the concept that was unlike anything we know today. To understand blockchain required us to forget the centrally controlled concepts that we were so used to, and not let our understanding of them interfere with what blockchain digresses into — a decentralized, distributed, transactional ledger.

We learnt more about Digital Signatures, Peer to peer networks (structured and unstructured), Cryptocurrency Hash codes, Anonymity and Pseudonymity in Cryptocurrencies. As we moved on, we understood why decentralized systems are considered more efficient.

Next, we were introduced to the Distributed Ledger, and it was interesting to learn how all blockchains are distributed ledgers but not all distributed ledgers are blockchains. We also saw the how one could decide what one’s application actually needed, as in…

Mining was a factor that held the curiosity of many, until we saw how Bitcoin mining involved very high processing power in order to process and validate Bitcoin transactions. This process requires solving advanced math problems of increasing difficulty levels to reach a valid Nonce. A Miner is a special type of node in a cryptocurrency network which processes and confirms transactions through what is called “mining”. We installed the Bitcore mining software and learnt how to mine.

In Ethereum the mining algorithm or Proof-of-work protocol called Ethash does not demand such high-power mining chips as are inherent in Bitcoin mining. It uses SHA-3 rather than the SHA-256 cryptography used by Bitcoin. The mining algorithm is similar to Bitcoin’s in that it requires the miner to find the correct Nonce. But it takes only around 12–15 secs, as compared to 10 mins in Bitcoin, for a miner to mine a block in Ethereum. Currently a block reward of 5 Ether is granted to the successful miner.

Gas is a means to pay for every operation performed on the Ethereum blockchain. Transaction cost is calculated based on Gas used and the Gas price.

Ethereum is also the most commonly used platform for implementing a blockchain application. It is much bigger than Bitcoin in the sense that it is an open blockchain platform that lets anyone build and use decentralized applications (Dapps).

A decentralized application (DApp) is essentially an application that runs on a decentralized, peer-to-peer network, making use of a Blockchain and Smart Contracts. Other development platforms for DApps are Hyperledger, OpenChain, Multichain.

The Ethereum Virtual Machine (EVM) is the engine in which transaction code is executed. Whisper and Swarm, two additional messaging and file sharing protocols, introduced by the Ethereum project, serve for exchanging messages and files. Geth and Parity are the two most popular Ethereum Clients.

Decentralized Autonomous Organization (DAO), is an organization that fully runs and is maintained on a blockchain, through smart contracts, programmed into the blockchain. In a DAO, the smart contracts establish how the organization should run and the organization runs automatically per these instructions. A Dapp may consist of multiple DAOs.

Here was something that everyone wanted to experience and see. Some wallets we discussed and even used were Copay (Bitcoin Wallet), Coinbase (Multi currency web wallet), MyEthereumWallet (Ethereum Wallet), etc. It was easy to create one’s own wallet using one of these, but we dealt with actual wallet implementation. It is not really advised to attempt wallet implementation from ground zero as some good open source options are available that already take care of security, scalability, etc. Copay itself is open source and uses Bitcore Wallet Service (BWS) for peer synchronization and network interfacing.

An interesting addon that proved invincible in accessing the Ethereum ecosystem was the MetaMask plugin, which allowed us to run Ethereum dApps in the browser without running a full Ethereum node. Incidentally MetaMask forms a bridge between the Ethereum network and the browser letting websites retrieve data from the blockchain and letting users securely manage identities and sign transactions.

Truffle is the most popular development framework for Ethereum. With Truffle, we get built-in smart contract compilation, linking, deployment, and network management for deploying to any number of public & private networks.

Truffle Boxes are helpful boilerplates that allow us to develop upwards of the basic functionality, and build our own unique dapps. In addition, Truffle Boxes can contain Solidity contracts & libraries, front-end views and more; all the way up to complete dapps.

We learnt how to create ERC20 Tokens and Initial Coin Offering (ICO) Contracts using Truffle and OpenZeppelin. While Truffle is most efficient framework for creating smart contracts and Dapps, OpenZeppelin is an extensive library of well tested smart contracts following security best practices. Just like Wallets, so also in the smart contract world, a small bug can cost much money. It is suggested not to reinvent the wheel when there are trusted solutions available openly. Testrpc is fast and developer friendly, and hence we used this as our blockchain node as we embarked upon creating and deploying our ICO smart contract.

Building a private blockchain using Ethereum, building Smart contracts, compiling and deploying them, and then configuring and running with the go-Ethereum client, helped us apply our knowledge in a real world like scenario.

While we gained ample technical knowledge on Blockchain, Cryptocurrencies, ICOs and their implementation, it was important to understand where the world was going with Blockchain, and how blockchain is essentially shaping the future of economics. Here are some use cases we discussed…

Blockchain in Land Registry

Real world problem: Buy/Sale process of property involves various formal procedures and has to go through many hands before the transfer is authenticated.
We can have a blockchain platform on which a Land-Registry Smart contract will allow the owner of the smart contract (Government/Development Authorities) to create properties (addresses) on the blockchain and allotting them to the proven owner (address). Now the properties can be traded on the blockchain. They can be transferred from one user to another over the blockchain without any central authority.

Blockchain in the world of Digital Identity and KYC

Currently all banks, financial institutions have to perform the KYC process individually. It is a long and cumbersome process and a blockchain-based registry could remove the duplication of effort in carrying out these KYC checks. The KYC ledger in the blockchain will also provide a historical record of all documents shared and compliance activities undertaken for each client. This will form the evidence to be provided to the regulators.
If KYC has to successfully move onto the blockchain, two criteria must be met. First the parties making the updates to the ledger must all be “trusted parties” such as company registries, law enforcement bureaus etc and second there must already be an international legal entity identifier to ensure that all trusted parties are updating the right record. Finally using some kind of private/hybrid blockchain where a set of parties can update and the rest can “read” off the blockchain, there could be a solution to KYC using the blockchain.

Add a comment

Related posts:

How To Finish What You Start

In my post yesterday I talked about how we tend to be great at planning things, but not so good at doing the things we had planned. “Simple? you say. There is nothing simple about dreaming, and…

5 Python Libraries We Love

Nylas is a Python shop, and while we use a lot of the Python libraries you’d expect to see in an email API codebase, like datetime, imaplib, and xml parsers, we also use a ton of open-source Python…

Peppermint Fudge Balls

Chocolate and peppermint seem to be a leading couple of the Christmas candy season and for good reason! It is a delicious combination! 1 cup almond butter 1 cup coconut oil, at room temperature 1/2…