Home > Enterprise >  Trying to do a nmap scan on a list of ip's. It won't go through the list with $
Trying to do a nmap scan on a list of ip's. It won't go through the list with $

Time:09-29

Please help I'm very new to this. Any help or references where i can get help are greatly appreciated. Shouldn't the $ be replaced with the ip's in the iplist?

for ip in $(cat iplist.txt); do sudo nmap -sS -p 80 -T4 $ip & done                                                                               

    12 ⚙
[14] 37884
[15] 37885
[16] 37886
[17] 37887
[14]    suspended (tty output)  sudo nmap -sS -p 80 -T4 $ip
[18] 37888
[19] 37889
                                                                                                                                                              
[18]    suspended (tty output)  sudo nmap -sS -p 80 -T4 $ip
[19]    suspended (tty output)  sudo nmap -sS -p 80 -T4 $ip
[15]    suspended (tty output)  sudo nmap -sS -p 80 -T4 $ip
[16]    suspended (tty output)  sudo nmap -sS -p 80 -T4 $ip
[17]    suspended (tty output)  sudo nmap -sS -p 80 -T4 $ip

CodePudding user response:

Not sure what your & is doing there. You might want to replace it with ;. So it reads - for ip in $(cat iplist.txt); do sudo nmap -sS -p 80 -T4 $ip; done

  • Related