Nmap is a security scanner application that probes computers connected to a network to find out their characteristics, available services and security vulnerabilities. Every Local Area Network (LAN) uses a contiguous interval of the Internet Protocol (IP) address space. Each computer in the LAN must have an IP address within that interval; however, some IP addresses within that interval may be unused (for example, not assigned to any computer) at any given time. You can use Nmap to generate a list of the unused IP addresses.
- Skill level:
Other People Are Reading
Log in to one of the computers connected to the LAN.
Identify a sample IP address within the LAN, and the network mask the LAN is using. The specific way of performing this step depends on the operating system. For example, on Linux, type the following command into a shell:
Press "Enter." The sample IP address is at the beginning of the second line in the output, after the "inet addr:" heading. The mask is at the end of the second line, after the "Mask:" heading.
Convert the network mask to binary by converting each of its four numbers to binary separately. For example, if the network mask is "255.255.252.0" in decimal, the binary representation is "11111111.11111111.11111100.00000000"
Count the number of ones in the binary representation of the mask to obtain the number of bits shared by all IP addresses in the LAN. For example, if the mask is "11111111.11111111.11111100.00000000" in binary, the number of shared bits is 22.
Invoke Nmap to have it probe all IP addresses in the LAN's address interval, and filter the output to list only the unused addresses. For example, on Linux, type the following command into a shell:
nmap -v -sP 192.168.0.32/22 | grep down
Replace "192.168.0.32" by the sample LAN IP address obtained in step 2. Replace "22" by the number of shared bits obtained in step 4. Press "Enter." The command will list all unused IP addresses in the LAN.
- 20 of the funniest online reviews ever
- 14 Biggest lies people tell in online dating sites
- Hilarious things Google thinks you're trying to search for