Date: Mon, 6 Jan 2003 18:12:09 -0800 (PST) From: Kelly Yancey <kelly@nttmcl.com> To: freebsd-net@FreeBSD.org Subject: Radix nodes, netmasks, and bogus sockaddrs, oh my! Message-ID: <20030106174323.H86820-100000@alicia.nttmcl.com>
next in thread | raw e-mail | index | archive | help
Is there any reason to fix the code in the kernel which assumes rt_mask(rt) is a properly-formed sockaddr? For example, sys/net/rtsock.c:sysctl_dumpentry() just passes rt_mask(rt)'s contents to userland to be interpretted as a sockaddr but it seldomly is a properly-formed sockaddr (i.e. sa_family is almost always garbage and sa_len is 0 for the default route). Nothing in the base system appears to care that the netmask isn't a full-fledged sockaddr so it isn't hurting anything. The main reason I ask is that interfaces such as sysctl_rtable and routing sockets are currently making stronger claims then they are living up to and I would be inclined to fix it. But if it were to be fixed, is there a preference for whether it should be corrected in the routing table itself or just when the information is exported? Thanks, Kelly To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030106174323.H86820-100000>