Summary
One of the objectives of this chapter was to find out about the modules that allow a port scanner to be performed on a specific domain or server. One of the best tools to perform port scouting in Python is python-nmap
, which is a module that serves as a wrapper to the nmap command. As we have seen in this chapter, Nmap can give us a quick overview of what ports are open and what services are running in our target network, and the NSE is one of Nmap's most powerful and flexible features, effectively turning Nmap into a vulnerability scanner.
With the help of the knowledge acquired in this chapter and the tools we have analyzed, you should be able to perform a pentesting process in relation to the ports and services exposed by a server in a given domain as well as detect possible vulnerabilities in those services.
In the next chapter, we will explore open source vulnerability scanners such as Nessus and OpenVAS and learn how to connect with them from Python to extract...