The consensus algorithm,as the underlying core technology of blockchain,is used to guarantee the consistency of data stored in each node in a decentralized blockchain system.It is the hot spot of current research in the field of blockchain.As one of the consensus algorithms,the Practical Byzantine Fault Tolerance(PBFT)algorithm can achieve a better operating effect.Therefore,it is widely used in the consortium blockchain.However,the lack of node behavior management and the large communication traffic in the consensus process leaves a large space for the PBFT algorithm to optimize.In this connection,this thesis conducts an in-depth study on the problems of the PBFT algorithm and explores feasible improvement measures to solve them.The main research contents are as follows:1.To address the problem that the PBFT algorithm lacks node consensus behavior management,which makes nodes with different attributes have the same status,resulting in poor system fairness and security,a node control mechanism based on the reputation model is proposed.Firstly,according to the performance in the consensus process,the credibility of each node is quantified.And based on the credibility evaluation results,the nodes are marked as different trust states,while the untrusted nodes are restricted from participating in the consensus process.Then the selection method of the primary node is optimized,and a larger voting weight is assigned to the primary node.Finally,a targeted node control mechanism is developed to regulate node behavior.The experimental results show that the improved scheme can effectively reduce the number of byzantine nodes involved in the consensus process compared to the original scheme,improving the system security and guaranteeing fairness.2.To address the problem of high communication complexity and high communication traffic between nodes in the consensus process of the PBFT algorithm,an improved PBFT algorithm based on grouping is proposed.Firstly,the node reliability is evaluated comprehensively,and nodes are divided into groups with different authorities based on the reliability difference.Then,the consensus protocol is simplified.The global communication mode is optimized to the primary-backup interaction form,reducing the communication complexity.At the same time,this thesis designs a protocol switching method to select the appropriate consensus protocol in different scenarios.Finally,a new node joins,and an old node exits method is presented to meet the node dynamic change requirements.Simulation experimental results confirm that the improved algorithm can effectively reduce the communication traffic between nodes in the consensus session and reduce the consensus delay.And it also shows a good performance in byzantine fault tolerance. |