command:
# less /etc/services
tcpmux 1/tcp # TCP port service multiplexer
echo 7/tcp
echo 7/udp
discard 9/tcp sink null
discard 9/udp sink null
systat 11/tcp users
daytime 13/tcp
daytime 13/udp
netstat 15/tcp
qotd 17/tcp
…….
2. Nmap with no arguments
To list ports used by various services in a host :
# sudo nmap scanme.nmap.org
PORT STATE SERVICE
22/tcp open ssh
25/tcp open smt
80/tcp open http
31337/tcp open Elite
3. Print the software version in a host
We can use the following command to print the versions of the software that are using the ports in the host:
# sudo nmap -sV scanme.nmap.org
PORT STATE SERVICE VERSION
22/tcp open ssh (protocol 2.0)
25/tcp open smtp?
80/tcp open http Apache httpd 2.4.7
31337/tcp open tcpwrapped
4. Scan for the host operating system
Nmap can also detect OS running on a remote host.
# sudo nmap -O scanme.nmap.org
PORT STATE SERVICE
22/tcp open ssh
25/tcp open smtp
80/tcp open http
31337/tcp open Elite
Device type: general purpose|WAP|broadband router
Running (JUST GUESSING) : Linux 2.6.X|2.4.X (86%)
Aggressive OS guesses: Linux 2.6.18 (86%), DD-WRT v23 (Linux 2.4.34) (85%), OpenWrt Kamikaze 8.09 (Linux 2.6.25.20) (85%), Linux 2.6.15 (Ubuntu) (85%), Linux 2.6.15 – 2.6.26 (85%), Linux 2.6.23 (85%), Linux 2.6.27.21-grsec (85%)
No exact OS matches for host (test conditions non-ideal).
Network Distance: 21 hops
5. Scan a number of hosts at once
Nmap can scan more than one host at a time.
For example, the following command will scan hosts ranging from …






0 Comments