Revolution in the field of wireless sensor network came with many research areas. Due to the dynamic topology and mobility of nodes, Wireless Sensor Networks (WSNs) are more vulnerable to security attacks than conventional wired and wireless network. Black hole attack is one of them. It is a very severe attack. The aim of this work is to provide the detection of black hole attack and provide a mechanism which is more satisfactory to prevent black hole attack in any circumstances. Black hole attack is a severe attack in the WSN. Actually the mobility of sensor nodes and open access medium etc. characteristics are responsible for these attacks. Security is the very important issue because some times people send sensitive data over wireless medium and people don’t want that nobody can get the data or access the data. If the data is related to the military application or security aspect of any country then data can be misused by any person. So to prevent from these types of mishap people want a secure environment in which data can be sent securely. Therefore many researches are going on in the field of security. And many researchers have given useful prevention against these attacks.