How does the blockchain work?

The technology a blockchain is a method of storage and up-dating (adding) of data in case of which the involvement of uniform plenipotentiary central node is not required.

The structure of any blockchain, when viewed as a distributed digital register (a kind of database), is a chain of linearly interconnected blocks (sets of certain data series) recorded in blockchain sequentially in chronological order (each new block can be added only to the last block of the chain).

Switching on of blocks in a blockchain happens to a certain interval of time (in a classical case though today there are also other principles of generation of blocks. For example, the principle of generation of blocks “as necessary”, that is only in the presence of the initiated transactions), and on each complete node defined a blockchain network is kept the copy of all this register automatically loaded by means of the special software after there is a connection of a node to a network.

Each such copy contains the complete information about all transactions, and as a result and all addresses and statuses, since the very first block (genesis bloc), finishing with the relevant last added block.

Depending on the specific implementation, the set parameters, the mechanism of confirmation of transactions and other elements of the system, functioning of different blockchains can differ, but in the most general case the sequence of generation and record of blocks can be described as follows:

1. The node of a network initiates the transaction, confirming its execution by means of the sign-code signature generated from a private key.
2. Data on transaction extend between participants of a peer-to-peer network of a blockchain on which nodes check transaction according to the mechanism of confirmation of transactions and beforehand the given criteria.
3. After the transaction is checked, it joins in the new block together with remaining current checked transactions, and the new block is transferred to a network and turns on in each copy of a blockchain. At this moment it is considered that transaction receives the first confirmation.
4. The generated block becomes a part of the register, and the following generated block cryptography will be connected to it in case of switching on in a blockchain that will be read by the second confirmation of the transaction.
5. Each subsequent block switched on in a blockchain, will mean that transaction receives one more confirmation. In case of achievement of a certain number of confirmations, depending on a specific blockchain, the transaction will be read completely confirmed and legitimate.

For implementation of blockchains peer-to-peer protocols (for the organization of the network by means of which there will be an interaction of participants), asymmetric cryptography and cryptography hashing (for support of security and the invariance of data, authentications, monitoring of accesses, transparency and a proveryamost of AND operations other), a consensus protocols are used (for support of mechanisms of achievement of coordination between network nodes).