One-time Key Generation Algorithm

Input: IDS, Posx, Posy

Output: Block Misbehaving Nodes

Begin

//Check misbehavior analysis

Analyze the traffic flow

If traffic flow is abnormal

//Initiate the key generation step

OT_Ki → IDS Å RP Å Posx Å Posy

// Check authentication

Receive the encrypted packet

If OT_K is invalid

Drop the current packet

Add to block list

Else

Perform data processing

End if

End if

End