计算机工程与应用 ›› 2024, Vol. 60 ›› Issue (7): 266-273.DOI: 10.3778/j.issn.1002-8331.2211-0144

• 网络、通信与安全 • 上一篇    下一篇

实用拜占庭容错共识算法的奖惩机制优化研究

张苗,李绍稳,吴雨婷,涂立静,张磊,杨尚雄   

  1. 1.安徽农业大学 信息与计算机学院,合肥 230036
    2.智慧农业技术与装备安徽省重点实验室,合肥 230036
  • 出版日期:2024-04-01 发布日期:2024-04-01

Research on Optimization of Reward and Punishment Mechanism of PBFT

ZHANG Miao, LI Shaowen, WU Yuting, TU Lijing, ZHANG Lei, YANG Shangxiong   

  1. 1.College of Information and Computer Science, Anhui Agricultural University, Hefei 230036, China
    2.Anhui Key Laboratory of Smart Agricultural Technology and Equipment, Hefei 230036, China
  • Online:2024-04-01 Published:2024-04-01

摘要: 联盟链是农业溯源行业的首选区块链方案,针对其核心共识机制实用拜占庭容错共识算法(PBFT)存在的共识安全性低、主节点出错概率大、通信开销大等问题,通过引入奖惩机制以及分组共识机制,提出了基于奖惩机制的改进实用拜占庭容错共识算法。把节点划分为4类,制定节点信誉规则,增强节点主动性,减少拜占庭节点的参与;剔除作恶节点参与共识资格,统计其余节点信誉值及票数,动态筛选信誉良好节点作为共识节点,并依据最高信誉值规则选取主节点,从而提升共识安全、降低拜占庭节点当选主节点概率;以PBFT共识为基础,将共识过程简化为组内共识及全局共识两个阶段,并基于最少广播消息数提出最优分组,缓解共识节点数目增多导致通信量过大的问题。实验结果表明,该方案能够有效抑制拜占庭节点,提升共识安全性能,降低共识成本。

关键词: 区块链, 共识算法, 奖惩机制, 分组共识

Abstract: The Alliance chain is the preferred blockchain scheme in the agricultural traceability industry. Aiming at the problems of low consensus security, high error probability of the primary node, and high communication overhead in the practical Byzantine fault-tolerant consensus algorithm of its core consensus mechanism, an improved practical Byzantine fault-tolerant consensus algorithm based on reward and punishment mechanism is proposed by introducing reward and punishment mechanism and grouping consensus mechanism. Firstly, the nodes are divided into four categories, and the node reputation rules are formulated to enhance the initiative of the nodes and reduce the participation of Byzantine nodes. Secondly, the qualification of malicious nodes to participate in consensus is excluded, and the reputation value and vote number of malicious nodes are counted. The nodes with good reputations are dynamically selected as consensus nodes. Moreover, according to the highest reputation value rule, the primary node is selected to improve the consensus security and reduce the probability of Byzantine nodes being elected as primary nodes. Finally, based on the PBFT consensus, the consensus process is simplified into two stages:intra-group consensus and global consensus. Based on the minimum number of broadcast messages, the optimal grouping is proposed to alleviate the problem of excessive communication caused by the increase of consensus nodes. Experimental results show that the scheme can effectively suppress Byzantine nodes, improve consensus security performance and reduce consensus cost.

Key words: blockchain, consensus algorithm, reward-punishment mechanism, group consensus