1- It begins when someone is doing single or group of transactions, transaction is actually a data transferred from one place to another and it can be cryptocurrency.
2- This transaction is send to large peer to peer network
These generally distribute all over the world
Each computer is called as node
They all have copy of data
3- Then transaction gets executed and validated on the basis of pre-shaped contracts and scripts.
This ensures that all node execute on the basis of same set of rules.
When transaction has executed the result is added to the blockchain.
It will be done on each node so you’ll have to compromise every node of a chain to compromise the transaction.
Characteristics of transactions in blockchain:
I – All are atomic (full or nothing)
Let’s say you have momentary transaction so you would want to ensure both credit on an account and debit on another is completed successfully if any of these fails the entire transaction should fail
Ii- We need to ensure that we are writing our transaction in right order in code.
Transactions run independently of each other, no interaction no dependency.
Iii- Inspectable means every single request or function call coming to the blockchain knows the address to the caller.
Iv- blockchain objects are immortal, means object never gets deleted or altered the only way to delete an object is to program it to delete itself.
The common hashing algorithm used with blockchain is SHA 256, it is checksum based hashing algorithm produces long string. It is signed by american national security agency. SHA is family of hashing algorithms. 256 is complexity of algo.
Common use of hash is storing password in db.
Using hash we can easily verify consistency of data for example if we have hashed complete website of wikipedia we will get a hash and if there is a little change even a coma in website content it will produce a different result so we can easily compare hashes to confirm if there is any change made or not.
So we do not need to store inital data to see if it is changed or not. All we need to store is initial hash.
Hashing algos are used in countless areas of modern security. For example in secure communication timestamps are exchanged.
It is hash of hashes, it allows to verify large amount of data
Block consists of data and its resulting hash. If you change any value in the block the hash will change and the block is invalid.
Block includes nounce. Nounce is input to the Hashing algorithm.
Its not possible to predict the nounce, it can be considered as proof of work by the machine creating the hash.
Mining the block:
If we want to have four leading zeros in our hash then we will keep running the algorithm until we figure out what nounce to set.
Block Number: it tells the order of block in blockchain.
Timestamp: Block contains a Timestamp
Hash of previous block: it contains hash of previous block this way it forms a chain and once you change any of the blocks hash gets changed and it breaks the chain.
The only way to fix this blockchain is to move down till the changed block and make the nounce hashses all over.
Securing your data
Data is on all the block in blockchain so you need to control who has your data
Obfuscatinon: making data relevant to only those who knows its meaning.
Example bitcion. Address of account is long string of letters and number and no one knows whose that address is physically connected to and no one needs to know even.
Its upto you if you want to stay anonymous or not.
If you share your account address then people will come to know that it’s you. Otherwise they don’t.
Encryption: there are many encryption algorithms to encrypt your information like Advance encryption standard (AES) it produces long key to produce heavy duty of encryption.
So now block can still be verified and evaluated by the participants of blockchain but the content will only be available to those with the keys.
Block chain can be public or private
Anyone can access to public
Private blockchain is like shared distributed database.
Ethereum : Microsoft, IBM Bluemix for those who wants to create their own blockchain.
One of the largest and well established blockchain
Very easy to use for private blockchain
Its about Consensus, non hacking possibilities, distributed trust
How pakistan govt deals with block chain
Andra pardesh moving its agriculture land records to block chain
Power distribution with blockchain, crypto currency
Trust, disintermediation problem should be solved by block chain
Bitcoin doesn’t define block chain
What is block chain on youtube by zlotolow..
Simple explanation of blockchain
Bitcoin and block chain
Bitcoin is digital money but we aren’t talking about it.
Technology enables moving digital coin from one individual to another. People don’t talk about bitcoin because of it s reputation but we can talk about blockchain as blockchain != bitcoin
Money transfer is typically done using a third trusted party.
But block chain does this without 3rd party.
And do it faster than 3days.
Let’s discuss 3important principles
1- Open ledger
Lets start with open ledger..
Here is a chain of transactions,
A started with initial value of $10
A wanted to move $5 to B
B wanted to move $3 to D
D wanted to move $1 to C
All these transactions are linked as can be seen in the image above
Now if A again wants to move $15 to C everybody know its not possible as A started with $10
Blockchain core idea is to get rid of centralized place
So above we can see open ledger is centralized it will be distributed now so here we need to provide a copy of this open ledger to everyone but they should remain synchronized too.
A and D are now holding a ledger.
Here in red is the un validated transaction, it is not getting into the ledger yet.
In order to get into the ledger we need to understand concept of miners.
So here let’s say A and D are miners the ones holding the ledger.
One miner will validate this transaction…
A miner needs to do 2 things
1- validate transaction
2- Find special key that will enable this miner to lock this new transaction to previous transaction. Miner repeatedly guess to find a key that match the previous transaction. This is random and takes computational power to find a matching one.
SO the first miner that will do that will get the financial revoult ( i.e. will make this immediate transaction) and will add this transaction to its own ledger.
Now every miner will add this validated transaction to their own ledgers.
The above process will continue in a loop.