Research Article

A Sequence Number Prediction Based Bait Detection Scheme to Mitigate Sequence Number Attacks in MANETs

Algorithm 1

Operation of adversary during Route discovery and data transmission [1, 3] (Algorithm 1 is reproduced from Rutvij et al. (2015), (under the Creative Commons Attribution License/public domain)).
Procedure 1: Actions by the malicious node after receiving an RREQ
Discard the received RREQ
If (RREQ is NOT for me) then
If (valid fresher route is available in the routing table) then
Fill up RREP with Dest_Seqno=Routing_table_Dest_Seqno+Random(1,7) and Hop_Count=Random(1,3)
Unicast the forged RREP on the reverse path to the source
End If
Else
Fill up RREP with own Seqno and Hop_Count=1
Unicast the genuine RREP on the reverse path to the source
(10) End If
Procedure 2: Actions by the malicious node after receiving a data packet from the source node
If (data packet is NOT for me) then
If (Packet_ID mod Random(1,3) == 0) then
Drop the data packet received from the source
Else
Forward the data packet
End If
Else
Receive the data packet for me
End If