Cool options in NMAP command


1.To identify how many Windows and Linux OS in a LAN environment.

Eg:

# nmap -F -O 192.168.1.1-15 | grep “Running: ” > /tmp/os; echo “$(cat /tmp/os | grep Linux | wc -l) Linux device(s)”; echo “$(cat /tmp/os | grep Windows | wc -l) Window(s) devices”

Output will be displayed like

0 Linux device(s)
1 Window(s) devices
#

2.To do an IDS scan or attack which gives a brief report such as

a.OSversion
b.Open ports
c.Network distance (How many hops to reach a particular server or pc)
d.Uptime of the server

Eg:
# nmap -T Aggressive -A –v IP Address or hostname

Customized output

Discovered open port 3389/tcp on IP Address
Discovered open port 5900/tcp on IP Address
Discovered open port 135/tcp on IP Address
Discovered open port 5800/tcp on IP Address
Initiating OS detection (try #1) against  Hostname or IP address
Host is up (0.0012s latency).
Device type: general purpose
Running: Microsoft Windows 7|2008
OS CPE: cpe:/o:microsoft:windows_7 cpe:/o:microsoft:windows_server_2008::sp1
OS details: Microsoft Windows 7 or Windows Server 2008 SP1
Uptime guess: 0.097 days (since Fri Nov  9 09:24:21 2012)
Network Distance: 2 hops

Advertisements

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: