NMAP扫描服务器端口开放情况

用法:

1.扫描单个网址或IP地址

如 :nmap 192.168.2.1/nmap www.xx.com

用UDP协议扫nmap -sU 192.168.2.1/nmap www.xx.com

显示如下:

Starting Nmap 7.91 ( https://nmap.org ) at 2021-11-09 01:47 EST

Nmap scan report for 192.168.2.1

Host is up (0.0080s latency).

Not shown: 993 closed ports

PORT STATE SERVICE

7/udp open|filtered echo

13/udp open|filtered daytime

19/udp open|filtered chargen

67/udp open|filtered dhcps

68/udp open|filtered dhcpc

MAC Address: A4:xx:xx:57:xx:6xx

2.扫描内网整个网段

如 nmap 192.168.12.0/24

3.扫描多个主机

nmap 192.168.2.10 192.168.1.20