Bitcoin helps to keep accounts
bookkeeping
because bookkeeping is a reward, each time you can add a certain number of bitcoin for yourself, so everyone is competing for bookkeeping, which of course leads to a problem: when there is inconsistency in bookkeeping, the system introces workload proof to solve the problem, and the rules are as follows:
1. In a period of time, only one person can succeed in bookkeeping
2. Obtain the unique bookkeeping right by solving the cryptography problem
3. Other nodes the bookkeeping results
but before the workload proof, The accounting node will do the following preparatory work:
1. Collect the original transaction information that has not been recorded in the broadcast
2. Check whether the payment address in each transaction information has enough balance
3. Verify whether the transaction has the correct signature
4. Package and record the verified transaction information
5. Add a reward transaction: add 12.5 to your address Bitcoin
if you succeed in competing for bookkeeping rights, you can get a reward of 12.5 bitcoin
workload proof
the hash value of the previous block and the current account page information will be hashed together as the original information in each bookkeeping. In order to ensure that only one person can keep accounts around 10 minutes, we have to improve the difficulty of keeping accounts. The results of hash must start with several zeros. In order to satisfy the condition, hash is to introce a random number variable
denoted by pseudo code:
1. Hash (last hash value, transaction record set) = 456635bcd
2. Hash (last hash value, transaction record set, random number) = 0000afd635bcd
if you change part of the original information of hash, the hash value will also change continuously. Therefore, when you run hash, the value of random number will change continuously, A random number can always be found so that the result of hash starts with several zeros. The node that finds the random number first obtains the unique bookkeeping right
verification
after the node successfully finds the hash value, it will broadcast and package the block to the whole network immediately, and the node of the network will verify it after receiving the broadcast. If the verification is passed, it indicates that a node has successfully decrypted, it will not compete for the current block, but will choose to accept the block and record it in its own account book for the next round of competitive guessing. Only the fastest decrypted block in the network will be added to the ledger, and other nodes will to ensure the uniqueness of the whole ledger
If a node has cheating behavior, it will cause the node of the network to fail the verification, give up its packaged block directly, and cannot be recorded in the general ledger, then the consumption cost of the cheating node will be in vain. Therefore, miners consciously abide by the consensus protocol of bitcoin system, and ensure the security of the whole system
it's like you go to the construction site to move bricks. After moving bricks for one day, the contractor asks you how can you prove that you move bricks for one day?
Zhejiang Xinyun blockchain Technology Co., Ltd. is a limited liability company (invested or controlled by natural person) registered in Ouhai District, Wenzhou City, Zhejiang Province on April 2, 2018. Its registered address is located in room B309, 46-54 Dongfang Road, Ouhai Economic Development Zone, Wenzhou City, Zhejiang Province (trial area of cloud sharing creative space)
the unified social credit code / registration number of Zhejiang Xinyun blockchain Technology Co., Ltd. is 91330304ma2cnkpx00, and the enterprise legal person is Xiao Kang. At present, the enterprise is in business
Zhejiang Xinyun blockchain Technology Co., Ltd., within the province, the current registered capital of the enterprise is general
view more information and information of Zhejiang Xinyun blockchain Technology Co., Ltd. through network enterprise credit
bookkeeping is done by miners
generally speaking, the correct result of Distributed Accounting is decided by the vote of "miners"
if you have a 51% pool, you can theoretically void any transaction (roll back). This is called a 51% attack
now bitcoin miners are distributed all over the world. The world's largest mine pool is in China, and the person in charge of bitcoin has promised that its total power will not exceed 50% (now about 30%), so there is no possibility of 51% attack for the time being
but it can't be said to conquer
because the miner will choose the transaction with high service charge among many transactions to pack, and the level of the service charge does not depend on the amount of money brought by the exchange, but on the amount of data of the transaction itself
therefore, even if there is no original reward, there is a handling charge for the miners, and the bookkeeping will continue.
at the beginning of bitcoin, you can get 50 bitcoin rewards from the system after one successful bookkeeping. Nakamoto designed a rule that for every 210000 blocks generated, the system reward of bitcoin will be halved. According to a block every ten minutes, 210000 blocks are four years. So every four years, bitcoin's system rewards are halved. 2012 was the first half, and July 2016 was the second. For now, we can get 12.5 bitcoin system rewards for successful bookkeeping. That's why so many people join the bitcoin network to participate in bitcoin bookkeeping.
