Due to lack of tamper-resistant hardware and broadcast nature of Wireless Sensor Networks (WSNs), security in sensor networks is one of the major concerns. WSNs consist of a large number of sensor nodes and a few sink nodes or storage node are used to collect information about the state of physical world and transmit it to interested users. It used in applications such as, health monitoring, habitat monitoring, military surveillance and environment sensing. Sensor nodes have limited resources in term of processing power, battery power and data storage. A sensor network that is not fully trusted that's why privacy is to be preserved.