# Detection and Mitigation of RPL Rank and Version Number Attacks in the Internet of Things: SRPL-RP
## 5 Discussion
### Network Performance Discussion  
From the analysis of the results in Section 4, we found that SRPL-RP in the grid-center topology, SRPL-RP (Rank Attack) in the grid-random topology, and SRPL-RP (Version Number Attack) in the random topology had the highest PDR and the best performance among other topologies compared with Standard RPL with Attacks, SBIDS [13], and RPL+Shield [14]. On the other hand, the effects of attacks in Standard RPL with Attacks was almost doubled in the random topology, causing routing errors with the majority of packets lost at the routing layer due to non-existing routes. Even though the SBIDS [13] provided detection against rank attack, it still had a lower impact by providing better PDR compared with our SRPL-RP (Rank Attack), especially in the grid-center topology, where the effect of rank attacks was almost doubled. The effect of the version number attack in RPL+Shield [14] was almost tripled in the grid-center topology, even though this provided mitigation of the attack compared with our SRPL-RP (Version Number Attack). These results show that the best average results for PDR can be extracted in the grid-center topology. This is because the nodes are placed in uniform distribution and densities, and this topology ensures that each node can reach only its vertical and horizontal neighbors during the simulation. Thus, this influences the RPL network and the number of parent nodes and child nodes that are created by the DODAG, in which a smaller number of parent nodes serve more child nodes. In the grid-random topology and random topology, each node may have more parent nodes. Hence, the parent nodes allow most of their child nodes to listen to the control messages. Thus, the DODAG of the RPL network can be constructed with more control messages. Therefore, PDR mainly depends on the node distribution and network topology; thus, nodes that have more child nodes have a higher probability of having a higher PDR. When the malicious nodes are closer to the root node, they can be easily detected by the proposed protocol. This is because, when the malicious nodes are far from the root node, it may take longer for the root node to realize that there is a change in the network. As a result, it becomes harder to be detected, and by the time the changes are recognized in the network by the root node, the rest of the legitimate nodes can be affected by the attack. We found that SRPL-RP in the random topology, SRPL-RP (Rank Attack) in the random topology, and SRPL-RP (Version Number Attack) in the random topology had the lowest and best performance in reducing the redundant amount of produced control messages compared with other topologies and compared with Standard RPL with Attacks, SBIDS [13], and RPL+Shield [14]. On the other hand, the effects of the attacks in Standard RPL with Attacks were higher in the grid-center topology. In addition, the number of generated control messages in SBIDS [13] is higher in the grid-center topology. Additionally, RPL+Shield [14] had more generated control messages even after applying the mitigation mechanism, especially in the random topology. This shows that the best average results for a control message were extracted in the random topology. This is due to the nature of topologies in which the malicious nodes spread in a random topology faster than in the grid-center and grid-random topologies that have a unified nature. This affects the number of parents and child nodes that create the DODAG and that have more parent nodes in random placements, in which the parent nodes allow fewer of their child nodes to listen to the control messages. Thus, the DODAG of the RPL network can be constructed with more control messages. Hence, the proposed SRPL-RP can reduce the effect of excess generated control messages and successfully mitigate the effect of the attacks. Thus, it prevents the malicious nodes from rebuilding the DODAG with higher parent nodes, and fewer control messages will be generated.