Research Article

Node Replication Attack Detection in Distributed Wireless Sensor Networks

Algorithm 1

SS-Predict.
Input: Input all the nodes in each region
Output: Filter the node has the same node id, node not updated in RWT table, Condition not satisfied nodes.
Description:
1.   Initialize the nodes
2.   if (Time=t) then
    UT[i]˂― (NID[i], Dij[i]); //update node id and distance should be updated
3.   For (j=1;j<=I;j++)
    If(NID[k]=NID[j]) or ( !list[j][table])
     Send the node to SS-Detect
4.   For(i=1 to node)
    m1[i]=pr[i]/(pr[i]+pl[i])
    m2[i]=pl[i]/(pr[i]+pl[i]
    m3[i]=delay/current time
    If(m1[i] < m1avg && m1[i]>m1avg)
    If(m2[i]<m2avg && m2[i]>m2avg)
    If(m3[i]<m3avg && m3[i]>m3avg)
      SSS-Detect(node[i])