Date: Tue, 6 Jan 2009 14:38:24 -0800 From: "Peter Steele" <psteele@maxiscale.com> To: <freebsd-questions@freebsd.org> Subject: RE: Do UDP broadcasts work in FreeBSD? Message-ID: <2ACA3DE8F9758A48B8BE2C7A847F91F2479E56@polaris.maxiscale.com> In-Reply-To: <2ACA3DE8F9758A48B8BE2C7A847F91F2479E3F@polaris.maxiscale.com> References: <2ACA3DE8F9758A48B8BE2C7A847F91F2479DF3@polaris.maxiscale.com><69A0F543-74D4-4D38-A0A5-A0EDE87A3DBB@mac.com> <2ACA3DE8F9758A48B8BE2C7A847F91F2479E3F@polaris.maxiscale.com>
next in thread | previous in thread | raw e-mail | index | archive | help
> I've already looked at the ISC DHCP source code. They use raw sockets to > send their broadcasts, which seems to us to be a convoluted way of > sending a simple broadcast. I've seen examples of DHCP client/server > code written in Java using standard UDP. Unfortunately, our own system > is already largely implemented in Java/Python, so we'll need to provide > a JNI interface to support raw sockets. Alternatively we may patch the > kernel to fix the bug at its source. Another option we're considering is to use the firewall to detect broadcasts and rewrite the MAC addresses in the outgoing packets. In looking at tcpdump output of broadcasts, the IP address is set to 255.255.255.255 and the MAC address is set to the MAC address of the gateway. On Linux boxes the MAC address is ff:ff:ff:ff:ff:ff, and that's the only significant difference in the packet. We thought we might be able to come up with a firewall rule to detect broadcasts and change the MAC address to the same as what Linux uses. I'm still in the process of researching this, but if someone can tell me this is impossible, I'll move on.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?2ACA3DE8F9758A48B8BE2C7A847F91F2479E56>