The Internet of Things (IoT) is the network of smart devices, sensors, and machines that continuously monitored the surrounding environment and execute meaningful decisions on the data or information it receives. The Internet-enabled devices could facilitate computer-mediated strategies for various tasks, for example, smart health care, managing the cities or smart factories, smart manufacturing, automating the home and business, etc. IoT commonly uses Internet technology for establishing communication among devices, thus inherits all the security threats that are currently affecting Internet users along with other security threats that are specific to IoTs due to resources constrained nature of the smart devices and sensors. The greater footprint, the distributed nature of the network and the existence of a huge number of IoT devices has also attracted criminals, fraudsters, and attackers to utilize this medium for spreading malicious content or making devices unavailable for legitimate use.It is imperative to ensure that the Confidentiality, Integrity, Security, and Privacy of information and users should remain intact while using these devices and thus they require an effective security system. Software-defined Networks (SDN) and Network Function are the way to control and configure devices from a centralized location and have been proven to offer scalability and versatility to their deployed ecosystems. In this paper, we systematically review the adoption of SDN and Network Function Virtualization (NFV) for securing the IoT network from emerging threats. To this extent, we provide a comprehensive survey on security solutions based on SDN, Blockchain, NFV, and SDN/NFV proposed for the security of the IoT network. We have also identified open challenges in this domain which includes lack of standardization, low cost, and effective machine learning systems for identifying malicious traffic and handling great attack surface and different attack vectors. The deployed technologies exhibit positive strides in their usage for the provision of security in IoT environments offering security enhancements, scalability, and versatility.