Messages in this thread | | | Subject | Re: all zeroes/all ones used in host IP's... | Date | Sat, 29 Jan 2000 01:12:00 +0100 | From | Magnus Danielson <> |
| |
From: Linux Lists <lists@cyclades.com> Subject: Re: all zeroes/all ones used in host IP's... Date: Fri, 28 Jan 2000 11:18:45 -0800 (PST)
> Let's consider the host 23.0.0.2 w/ subnet 255.255.255.0 (which is in the > network 23.0.0.0/24). From what I know about IP (which could be wrong, so > please correct me if this is the case), we have: > > - Host-number = 0x02 (last 8 bits, as defined by subnet mask) > - Network-number = 0x170000 (first 24 bits, as defined by the > subnet mask) > - Subnet-number = 0xFFFFFF00 > > None of them is 0 or -1 and, thus, the IP address is valid. > > I hope this clarifies your doubt. Be careful with name definitions ... ;)
Actually, if you read the RFC 1122 section 3.2.1.3 you would indeed find that for you example you get
Host-number = 0x02 Subnet-number = 0x0000 Network-number = 0x17
So, the subnet number would actually break the rules of section 3.2.1.3 which he was refering to:
IP addresses are not permitted to have the value 0 or -1 for any of the <Host-number>, <Network-number>, or <Subnet- number> fields (except in the special cases listed above). This implies that each of these fields will be at least two bits long.
Now, much traffic has flown through the bridges since then. The introduction of CIDR has cause us to leave the 3-tuple form for the 2-tuple form of
{ network address, mask count }
Also, the special uses which would prohibit Subnet-number to be either all 0's or all 1's is not of general interest anymore and is not being used. I don't recall that they have been formally deprechiated thougth. Actually, I don't think many people care about those anymore. CIDR should really make this exception go away since it will actually defeat some of the reasons for using CIDR.
Cheers, Magnus
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |