Research Article
A Security and Efficient Routing Scheme with Misbehavior Detection in Delay-Tolerant Networks
Algorithm 3
Security and efficient routing algorithm.
(1)if node meets node then | (2)node triggers Algorithm 2 and detects behavior of | node ; | (3)get detection result of node from Algorithm 2; | (4)end | (5)if node is a well-behavior node and then | (6)sorts messages by the remaining ; | (7)for each message do | (8)get destination node from head field of ; | (9)get of node and node | from ; | (10)if then | (11)get copy number from head field of ; | (12)calculate using Eq. (8); | (13)forwards a copy of with copy number | to node ; | (14)updates ; | (15)else | (16)if and then | (17)calculate of node and node ; | (18)if and then | (19)forwards a copy of to node ; | (20)else | (21)if then | (22)get copy number from head | field of ; | (23)calculate using Eq. (9); | (24)forwards a copy of with copy | number to node ; | (25)updates ; | (26)end | (27)end | (28)else | (29)end | (30)end | (31)end |
|