Here we automate NMAP scans to only scan production servers IP’s rather than an entire network.
Step 1 – Use Notepad to create a list of IP’s to scan
Notepad+ was used, enter in the IP’s to scan. Avoid the use of hostnames – use IP’s.
Create a directory called nmap. c:nmap.
Create a file called scan_me.txt (use notepad or notepad+). c:nmapscan_me.txt
Step 2 – Use Zenmap the Gui for NMAP
Enter the path to the scan_me.txt.
nmap -sP -iL c:nmapscan_me.txt
Step 3 – Scan Results
Note that only the IP’s within the scanme.txt file were scanned. This is how you automate scanning.