| With the rapid growth of blocks in blockchain,blockchain nodes are facing with the problem of large-capacity storage caused by the generation of a large number of blocks,so it is very necessary to optimize the storage of blockchain nodes.In this paper,aiming at the capacity and security problems existing in the traditional fragmentation storage scheme,an improved fragmentation storage scheme is proposed.The main research work is as follows:(1)Fragmentation storage scheme based on the tampering probability of the latest block of fragmentation.In the traditional fragmentation scheme,the strategy of copies is fixed to set the tampering probability of the least numbered block as the tampering probability of the fragmentation.As it is small,and the number of fragmentation copies are also small,the probability of fragmentation being stored by the malicious nodes increases.To solve this problem,this paper proposes a fragmentation storage scheme based on the tampering probability of the latest block of fragmentation.The tampering probability of the largest numbered block in the fragmentation is set to be the current fragmentation tampering probability,increasing the number of fragmentation copies and reduce the probability of fragmentation being stored by malicious nodes.(2)Dynamic method for determining the minimum number of fragmentation copies.The traditional fragmentation storage scheme usually sets the minimum number of fragmentation copies to a constant value,which will also increase the probability of being tampered with the fragmentation by malicious nodes.According to the 51% attacked principle of blockchain,when the number of fragmentation copies saved by the honest nodes exceeds that of the malicious nodes,the storage of the minimum number of fragmentation copies is considered to be safe.In order to improve the security of block storage in blockchain,this paper proposes a method to determine the minimum number of fragmentation copies that can be dynamically adjusted,and set the number of stored nodes to meet the 51% attacked principle of blockchain.(3)Node security mechanism based on security block.Because of the randomness of the storage scheme proposed above,it is possible that fragmentation can be stored by malicious nodes.This paper proposes a safe block in the blockchain to record the security value of the node,so that the system select the appropriate storage node to store fragmentations for improving the security of fragmentation storage.In this paper,the above schemes are simulated in the simple bitcoin distributed system,and experiments show that the improved scheme can be significantly optimized in storage space and security. |