Si realizamos el típico TCP SYN scan podremos ver los test sobre los puertos comunes (que además están en el fichero nmap-services identificados con una descripción)
root@scatha:/home/vampii# nmap -sS scanme.nmap.org
Starting Nmap 5.51 ( http://nmap.org ) at 2012-01-25 13:32 ART
Nmap scan report for scanme.nmap.org (74.207.244.221)
Host is up (0.28s latency).
Not shown: 993 closed ports
PORT STATE SERVICE
22/tcp open ssh
37/tcp filtered time
80/tcp open http
135/tcp filtered msrpc
139/tcp filtered netbios-ssn
445/tcp filtered microsoft-ds
9929/tcp open nping-echo
Nmap done: 1 IP address (1 host up) scanned in 18.59 seconds
Pero podemos comprobar como algunos puertos no son detectados, por ejemplo el 5422. Para probar un puerto específico podemos indicarlo mediante la opción -p:
root@scatha:/home/vampii# nmap -sS scanme.nmap.org -p 5422
Starting Nmap 5.51 ( http://nmap.org ) at 2012-01-25 13:36 ART
Nmap scan report for scanme.nmap.org (74.207.244.221)
Host is up (0.23s latency).
PORT STATE SERVICE
5422/tcp closed unknown
Nmap done: 1 IP address (1 host up) scanned in 1.12 seconds
root@scatha:/home/vampii#
Mediante esta opción podemos indicar rangos, como del 50 al 90 con -p50-90:
root@scatha:/home/vampii# nmap -sS scanme.nmap.org -p 50-90
Starting Nmap 5.51 ( http://nmap.org ) at 2012-01-25 13:37 ART
Nmap scan report for scanme.nmap.org (74.207.244.221)
Host is up (0.88s latency).
Not shown: 39 closed ports
PORT STATE SERVICE
67/tcp filtered dhcps
80/tcp open http
Nmap done: 1 IP address (1 host up) scanned in 6.91 seconds
root@scatha:/home/vampii#
O bien indicarlos todos mediante un guión (-p-), con dicha opción veremos como tarda bastante en acabar:
root@scatha:/home/vampii# nmap -sS scanme.nmap.org -p-
Starting Nmap 5.51 ( http://nmap.org ) at 2012-01-25 13:37 ART
Nmap scan report for scanme.nmap.org (74.207.244.221)
Host is up (0.36s latency).
Not shown: 65523 closed ports
PORT STATE SERVICE
22/tcp open ssh
37/tcp filtered time
67/tcp filtered dhcps
80/tcp open http
135/tcp filtered msrpc
136/tcp filtered profile
137/tcp filtered netbios-ns
138/tcp filtered netbios-dgm
139/tcp filtered netbios-ssn
445/tcp filtered microsoft-ds
547/tcp filtered unknown
9929/tcp open nping-echo
Nmap done: 1 IP address (1 host up) scanned in 2281.40 seconds
root@scatha:/home/vampii#
Tomado de: http://systemadmin.es/2011/10/escanear-todos-los-puertos-tcp-con-nmap (pero actualizado).
No hay comentarios:
Publicar un comentario