# A Robust Sharding-Enabled Blockchain with Efficient Hashgraph Mechanism for MANETs
## 1 Introduction
Furthermore, if each shard is constructed by nodes with geographical proximity, it not only improves communication efficiency in the intra-sharding consensus but also reduces the number of cross-shard transactions related to geographic information. Nevertheless, the dynamic addition and deletion of nodes make shards more vulnerable to being compromised, which is the motivation of our work. Reputation-based asynchronous consensus in VANETs alleviates these attacks to some extent [23; 24]. Since we only consider the movement of nodes, the VANET is regarded as one kind of MANET. In [PERSON] et al. [23], nodes whose reputation values are lower than a given threshold are regarded as malicious ones, and the consensus threshold is calculated based on the number of malicious nodes within a shard. After a block is generated through PoW resolution, nodes add their signatures into the block for validation and propagate it to neighbor nodes. Only when the number of attached validation signatures of the block is larger than the consensus threshold is the block sent to a nearby RSU (Road Side Unit) for synchronizing to other nodes. Thus, even though malicious nodes come into a shard, the consensus threshold increases and the attack cost rises accordingly. In [PERSON] et al. [24], nodes with high reputation values are randomly selected into a hashgraph committee, becoming a primary and primary candidates. In the process of hashgraph consensus, the primary packs validated events into a block. Then, the block is confirmed by accounting nodes based on  
Figure 1: Logical topologies of blockchain networks with different consensus protocols. the majority, and it is recorded in the chain. The members of the hashgraph committee are fixed, while newcomers become accounting nodes dynamically. Since the primary and primary candidates are authenticated by a certificate authority and their voting weights are related to reputation scores, the Sybil attack can be prevented. Therefore, we propose a behavior-based sharding hashgraph for nodes dynamically joining and leaving a shard in MANETs. However, it needs to overcome the challenges of robust shards and efficient hashgraph consensus. **Robustness**. The reputation of nodes should not be centrally managed by a third party, e.g., a trust authority [23] or a certificate authority [24]. It is because the single point is potential risks. Moreover, if a shard is compromised, a recovery mechanism is necessary to restore the transactions generated by honest nodes in the blockchain. **Efficiency**. The transmission delay is relatively high in MANETs due to dynamic changes of neighbor nodes [25]. Dishonest gossip, which is used to propagate false gossip or not to propagate received gossip to neighbors, aggravates the latency of blockchain updates. In order to address the above challenges, our contribution is as follows:  
* A sharding hashgraph framework with a blacklist is proposed for the MANET-based blockchain. In each shard, the blacklist records the dishonest consensus activities of nodes in a decentralized manner. With the assistance of the blacklist, gossip information is sent to a reliable neighbor, and gossip information from another reliable neighbor is received first. It improves the efficiency of gossip about gossip in hashgraph consensus. * A tree-assisted inter-sharding consensus is proposed to prevent Sybil attacks. A tree, \(tree^{je}\), whose root is the participation request of a node, is constructed by all involved shards. Based on \(tree^{je}\), the requester with enough reputation values is allowed to join the shard, and its reputation values cannot be reused in other shards. Furthermore, transactions of the requester can be updated to the graph, and the requester propagates gossip information first. Once the requester is allowed to join the shard, its updated transactions can be used directly, and previous virtual voting is counted in hashgraph consensus. Hence, the requester can participate in activities of the shard without waiting.