Why should you care about Blockchain technology?
Around 2008 and 2009, when the institutions and markets we trusted went crumbling down, and everybody was running away from the Wall Street, a person called Satoshi Nakamoto, introduced a new digital currency, a cryptocurrency called Bitcoin on 3rd January 2009.
Bitcoin enabled an innovative platform for the peer-to-peer transfer of value with no central authority. With no central authority, how did Bitcoin realize trust and security? By implementing software programs for validation, verification, the consensus in a novel infrastructure called the blockchain.
The technology behind Bitcoin
Blockchain is a technology created to support Bitcoin. Unlike traditional methods, this technology enables peer-to-peer transfer of digital assets with no intermediaries in a decentralized network. Establishing trust among unknown peers. Recording the transaction in an immutable distributed ledger. It is a decentralized digital currency without a central bank or single administrator that can be sent from user to user on the peer-to-peer bitcoin network with no intermediaries. The technology has taken a life of its own and spread itself in a broad range of applications across many industries, including finance, healthcare, government, manufacturing, and distribution.
The blockchain poise to innovate and transform a wide range of applications, including goods transfer, for example, the supply chain. Digital media transfer, for example, sale of art. Remote services delivery, for example, travel and tourism. A platform for decentralized business logic, for example, moving computing to data sources. And distributed intelligence, for example, education credentialing. Additional applications of blockchain include distributed resources, for example, power generation and distribution. Crowdfunding, for example, start-up fundraising. Crowd operations, for example, electronic voting. Identity credentialing, for example, one ID for all your life’s functions. And government public records and open governing.
Centralized versus Decentralized Network
The intermediaries involved in a common centralized network are a credit card agency, a customer bank, a credit card bank, an exchange, the merchant’s bank, and finally, the merchant. Now compare this with a system where peers can transact directly with each other irrespective of their location and no intermediaries involved in the transaction. How much safer can a transaction be?
It shifts the functions of the intermediaries in a transaction to the peer participant in the blockchain infrastructure. Peers do not necessarily know each other before, during, or even after the transaction. This is a decentralized system. Then how do we establish trust among the peers in such a decentralized system? By having a process in place to validate, verify, and confirm transactions, then record the transaction in a distributed ledger of blocks, create a tamper-proof record of blocks, chain of blocks, and implement a consensus protocol for agreement on the block to add to the chain. So, validation, verification, consensus, and immutable recording lead to the trust and security of the blockchain.
The basic element of the Bitcoin Blockchain is the transaction. Transactions are validated and broadcasted to further form a block. A block is composed of a header of information about the block, and a set of valid transaction. Multiple blocks form a chain using digital data links. Each block goes through a consensus process, to select the next block that will be added to the chain. The chosen block is verified and added to the current chain. The validation and consensus process of a block is carried out by special peer nodes called miners. Miners are powerful computer executing software defined by the blockchain protocol.
Unspent Transaction Output, UTXO
A fundamental concept of a bitcoin network is an Unspent Transaction Output, also known as UTXO. The set of all UTXOs in a bitcoin network collectively define the state of the Bitcoin Blockchain. They are referenced as inputs in a transaction and outputs generated by a transaction. All of that UTXO’s is in a system, are stored by the participant nodes in a database.
Role of the UTXO’s in a Bitcoin Blockchain
The transaction uses the amount specified by one or more UTXOs and transmits them to one or more newly created output UTXOs, according to the request initiated by the sender. The structure of a given UTXO is very simple, it includes a unique identifier of the transaction (that created this UTXO), an index (the position of the UTXO in the transaction output list), a value (or the amount it is good for) and an optional script (the condition under which the output can be spent). The transaction itself includes a reference number of the current transaction, references to one or more input UTXOs, references to one or more output UTXOs newly generated by the current transaction, and the total input amount and output amount. Participants can validate the transaction contents.
Does the UTXO’s reference input exist in the network state? This is the only one of the many validation criteria.
The basic operations in a blockchain
Operations in the decentralized network are the responsibility of the peer participants and their respective computational nodes. These operations include validation transactions, gathering the transactions for a block, broadcasting the ballot transactions in the block, and consensus for the next block creation to chain the blocks to form an immutable record.
There are two major roles for the participants. Participants that initiate a transfer of value by creating a transaction and additional participants called miners, who pick on added work of computation to verify transactions, broadcast transaction, compete to claim the right to create a block, work on reaching consensus by validating the block, broadcasting the newly created block, and confirming transactions.
Why participants would take on additional work? Well, the miners are incentivized with bitcoins for the efforts in managing the blockchain. Transaction validation is carried out independently by all miners. The process involves the validation of more than 20 criteria, including size, syntax, etc. Some of these criteria are referenced Input Unspent Transaction Output, UTXOs are valid, reference output UTXOs are correct, reference input amount and output amount matched sufficiently, invalid transactions are rejected and will not be broadcast. All the valid transactions are added to a pool of transactions. Miners select a set of a transaction from this pool to create a block.
This creates a challenge. If every miner adds the block to the chain, there will be many branches to the chain, resulting in an inconsistent state. But, the blockchain is a single consistent linked chain of flux. So, we need a system or a solution to overcome this challenge.
Miners compete to solve a puzzle to determine who will earn the right to create the next block. In the case of Bitcoin blockchain, this parcel is a computation of parcel and the central processing unit or CPU intensive. Once a miner solves the puzzle, the announcement is broadcast to the network along with the block, and other participants verify the new block. Participants reach a consensus to add a new block to the chain, this new block is added to their local copy of the blockchain. Thus, a new set of transactions are recorded and confirmed. The algorithm for consensus is called proof-of-work protocol since it involves the working of computational power to solve the puzzle and to claim the right to form the next block.
Transaction zero, index zero of the confirmed block is created by the miner of the block. It has a special UTXO and does not have any input UTXO. It is called the coinbase transaction that generates a minor’s fees for the block creation. Currently, the minor’s fees is 12.5 BTC for a bitcoin. This is how a new coin is maintained in bitcoin.
Therefore, the main operations in a blockchain are transaction validation and block creation with the consensus of the participants. There are many underlying implicit operations as well in the bitcoin blockchain.
Well, Bitcoin is not the only player in town.
There is a new generation blockchain beyond Bitcoin, ETHEREUM blockchain.
Bitcoin supports an optional and special feature called scripts for conditional transfer of values. Ethereum Blockchain extended the scripting feature into a full-blown code execution framework called smart contract. A smart contract provides the very powerful capability of code execution for embedding business logic on the blockchain.