summaryrefslogtreecommitdiff
path: root/usr.sbin/mrouted
diff options
context:
space:
mode:
authorClaudio Jeker <claudio@cvs.openbsd.org>2022-05-06 15:51:10 +0000
committerClaudio Jeker <claudio@cvs.openbsd.org>2022-05-06 15:51:10 +0000
commite8f5f57010005abc96edffdf46485c65739e6370 (patch)
treeb37f6fdfa387c5d3d5aa30750f9dc9611eea91e7 /usr.sbin/mrouted
parentd3eccde1ef5b43e23ed27dfcc3d080ea90d5f228 (diff)
Relax the limitation of what is an acceptable unicast IP.
Remove the IN_BADCLASS() check which filters out the experimental IPv4 address space. Now there are no more experiments in IPv4 and so there is less reason for these network daemons to deny such an IP. Everything still disallows multicast IPs (224/4) and loopback (127/8) a few also disallow 0/8 but this is not consistent. In any case using 240/4 in production is a really bad idea but it is not up to this software to prevent you from being a fool. OK deraadt@ tb@
Diffstat (limited to 'usr.sbin/mrouted')
-rw-r--r--usr.sbin/mrouted/inet.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/usr.sbin/mrouted/inet.c b/usr.sbin/mrouted/inet.c
index 4f00bc6d9ba..d433d51cc28 100644
--- a/usr.sbin/mrouted/inet.c
+++ b/usr.sbin/mrouted/inet.c
@@ -36,7 +36,6 @@ inet_valid_host(u_int32_t naddr)
addr = ntohl(naddr);
return (!(IN_MULTICAST(addr) ||
- IN_BADCLASS (addr) ||
(addr & 0xff000000) == 0));
}
@@ -83,7 +82,7 @@ inet_valid_subnet(u_int32_t nsubnet, u_int32_t nmask)
(subnet & 0xff000000) == 0x7f000000 ||
(subnet & 0xff000000) == 0x00000000) return (FALSE);
}
- else if (IN_CLASSD(subnet) || IN_BADCLASS(subnet)) {
+ else if (IN_CLASSD(subnet)) {
/* Above Class C address space */
return (FALSE);
}