Text this: Detecting and Defending against Replication Attacks in Wireless Sensor Networks