IP Subnet Notation

ip addressnotationsubnet

On a lab to regarding network topology using port scanners, I am instructed "to develop a network inventory and topology for the 123.218.44.0/24 subnet."

What does the notation 0/24 mean there? I had assumed it meant to consider the network range 123.218.44.0 to 123.218.44.24. When I use nmap against a range, using parameters in this format:

nmap -sS -O 123.218.44.0/24

nmap reports that it scanned 256 hosts, presumably 123.218.44.0 to 123.218.44.255. There is only one host between 0 and 24, but there are 4 hosts between 101 and 255. I assume that I am meant to find all 5 of those hosts, but I don't understand the notation so I'm not sure. Can anyone clarify for me?

Best Answer

That's Classless Inter-Doman Routing notation. The /24 means that the routing prefix of the subnet is 24 bits long, which means there's ony 8 bits left for the subnet itself, i.e. 123.218.44.0 to 123.218.44.255