Design and Implementation of TARF: A Trust-Aware Routing Framework for WSNs(2012)

Note: Please Scroll Down to See the Download Link.


The multi-hop routing in wireless sensor networks (WSNs) offers little protection against identity deception through replaying routing information. An adversary can exploit this defect to launch various harmful or even devastating attacks against the routing protocols, including sinkhole attacks, wormhole attacks and Sybil attacks. The situation is further aggravated by mobile and harsh network conditions. Traditional cryptographic techniques or efforts at developing trust-aware routing protocols do not effectively address this severe problem. To secure the WSNs against adversaries misdirecting the multi-hop routing, we have designed and implemented TARF, a robust trust-aware routing framework for dynamic WSNs. Without tight time synchronization or known geographic information, TARF provides trustworthy and energy-efficient route. Most importantly, TARF proves effective against those harmful attacks developed out of identity deception; the resilience of TARF is verified through extensive evaluation with both simulation and empirical experiments on large-scale WSNs under various scenarios including mobile and RF-shielding network conditions. Further, we have implemented a low-overhead TARF module in Tiny OS; as demonstrated, this implementation can be incorporated into existing routing protocols with the least effort. Based on TARF, we also demonstrated a proof-of-concept mobile target detection application that functions well against an anti-detection mechanism.

Existing System

In Existing system, when the file send from base station in that situation hackers aggravated network conditions. A traditional cryptographic techniques effort does not address the severe problems. That time the file could be affected by hackers. So, the network will be damaged. An attacker may tamper nodes physically, create traffic collision with seemingly valid transmission, drop or misdirect messages in routes, or jam the communication channel by creating radio interference.

Proposed System

In Proposed System, focuses on the kind of attacks in which adversaries misdirect network traffic by identity deception through replaying routing information. Based on identity deception the adversary is capable of launching harmful and hard to detect attacks against routing, such as selective forwarding, wormhole attacks, sinkhole attacks, and Sybil attacks.


1.      Routing the Network

2.      Transfer File

3.      Sinkhole and Wormhole Attacks

4.      Energy Watcher & Trust Manager          

Modules Description

1.      Routing the Network

In this module, the networks embedded on the physical fiber topology. However, assessing the performance reliability achieved independent logical links can share the same physical link, which can lead to correlated failures. Mainly, we focus on assessing the reliability of energy level and trusted network.

2.      Transfer File

In this module, Analysis the Shortest Path algorithm independently routes each logical link on a physical path with the minimum number of hops in trusted network basis. Since we are assuming that every physical link fails with the same probability, the failure probability of path is minimized when it is routed over the shortest path. Hence, under the algorithm Shortest Path, each light- path greedily takes the most reliable route and transfers the file.

3.      Sinkhole and Wormhole Attacks

·         Prevent the base station from obtaining complete and correct sensing data

·         Particularly severe for wireless sensor networks

·         Some secure or geographic based routing protocols resist to the sinkhole attacks in certain level

·         Many current routing protocols in sensor networks are susceptible to the sinkhole attack

·         Set of sensor nodes

*      continuously monitor their surroundings

*      forward the sensing data to a sink node, or base station

·         Many-to-one Communication

*      vulnerable to the sinkhole attack, where an intruder attracts surrounding nodes with unfaithful routing information

*      alters the data passing through it or performs selective forwarding

4.      Energy Watcher & Trust Manager

In this module Cluster-based WSNs allows for the great savings of energy and bandwidth through aggregating data from children nodes and performing routing and transmission for children nodes. In a cluster-based WSN, the cluster headers themselves form a sub-network, after certain data reach a cluster header, the aggregated data will be routed to a base station only through such a sub-network consisting of the cluster headers. Our framework can then be applied to this sub-network to achieve secure routing for cluster based WSNs.

Trust Manager encourages a node to choose another route when its current route frequently fails to deliver data to the base station. Though only those legal neighboring nodes of an attacker might have correctly identified the adversary,



·         System                  :           Pentium IV 2.4 GHz.

·         Hard Disk                         :           40 GB.

·         Floppy Drive         :           1.44 Mb.

·         Monitor                 :           15 VGA Color.

·         Mouse                   :           Logitech.

·         Ram                       :           512 MB.


·         Operating system              :           Windows XP Professional.

·         Coding Language             :           C#.NET

Click here to download Design and Implementation of TARF: A Trust-Aware Routing Framework for WSNs(2012) source code