A script to check ports of a long range of IPs
Hi,
i want to create a script that will check the ports of a range of IPs. I could write all the IPs, but i have thought there is maybe a way to write the rage instead of all the IPs. Is that true? Do you advice any language to write this kind of scripts? Çiao |
Hi,
You could use nmap Code:
nmap -p 80,22 10.0.0.0/24 |
Thanks!,
the next question im wondering is: If i get this result, Starting Nmap 4.76 ( http://nmap.org ) at 2009-07-06 11:57 CEST Interesting ports on localhost (127.0.0.1): PORT STATE SERVICE 80/tcp closed http then, I would like to write in a log file: 127.0.0.1: 80 CLOSED How would you do that? Ciao |
nmap A.B.C.D/X -oN <logfile>
or nmap A.B.C.D/X -oG <logfile> |
All times are GMT -5. The time now is 06:45 PM. |