Skip to content

Instantly share code, notes, and snippets.

@zeroxia
Created March 19, 2014 08:18
Show Gist options
  • Save zeroxia/9637504 to your computer and use it in GitHub Desktop.
Save zeroxia/9637504 to your computer and use it in GitHub Desktop.
nmap command to scan the network
#!/bin/sh
#IFACE=eth1
# # LAN host discovery
# seq 0 255 | while read subnet; do
# echo subnet: 192.168.$subnet.0
# ##sudo ifconfig $IFACE 192.168.$subnet.100
# ##sudo nmap -n -sP -PA 192.168.$subnet.-99,101-
# done
# Host port scan
##sudo nmap -v -n -sS -sU -p T:-,U:- -PN 192.168.0.120
subnet=249
sudo nmap -n -sP -PA 192.168.$subnet.-89,91-
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment