Lines Matching defs:subnet
25 * (Without a mask, cannot detect addresses of the form {subnet,0} or
26 * {subnet,-1}.)
57 * Verify that a given subnet number and mask pair are credible.
59 * With CIDR, almost any subnet and mask are credible. mrouted still
61 * otherwise the only requirements are that the subnet address is
62 * within the [ABC] range and that the host bits of the subnet
68 u_int32_t subnet, mask;
70 subnet = ntohl(nsubnet);
73 if ((subnet & mask) != subnet) return (FALSE);
75 if (subnet == 0)
78 if (IN_CLASSA(subnet)) {
80 (subnet & 0xff000000) == 0x7f000000 ||
81 (subnet & 0xff000000) == 0x00000000) return (FALSE);
83 else if (IN_CLASSD(subnet) || IN_BADCLASS(subnet)) {
87 if (subnet & ~mask) {
88 /* Host bits are set in the subnet */
116 * Convert an IP subnet number in u_long (network) format into a printable