Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 25 Aug 2016 07:45:22 +0000
From:      "Meyer, Wolfgang" <wolfgang.meyer@hob.de>
To:        'Ryan Stone' <rysto32@gmail.com>, freebsd-net <freebsd-net@freebsd.org>
Subject:   RE: How can I send packets to 255.255.255.255 from the command line?
Message-ID:  <EC88118611AE564AB0B10C6A4569004D015C057C24@HOBEX11.hob.de>
In-Reply-To: <CAFMmRNwXKhNUg35eYS4bE4UZQxTrAhYDatnokDuMtTT33SUMwQ@mail.gmail.com>
References:  <CAFMmRNwXKhNUg35eYS4bE4UZQxTrAhYDatnokDuMtTT33SUMwQ@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help


> -----Original Message-----
> From: owner-freebsd-net@freebsd.org [mailto:owner-freebsd-
> net@freebsd.org] On Behalf Of Ryan Stone
> Sent: Donnerstag, 18. August 2016 21:30
> To: freebsd-net
> Subject: How can I send packets to 255.255.255.255 from the command line?
>
> I want to test a change to broadcast packet handling and I want to confir=
m
> that 255.255.255.255 is still handled correctly. Are there any command-li=
ne
> tools in FreeBSD that can send to the broadcast address?  ping
> 255.255.255.255 does not work correctly, unfortunately.
> _______________________________________________
> freebsd-net@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-net
> To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org"

Hello,

this is a long-standing bug in the FreeBSD network implementation. The situ=
ation has not changed since the examination done in comment 10 of this prob=
lem report:

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D99558

In order to be able to send packets to the 255.255.255.255 IP address you n=
eed to change the kernel sources. I have developed a patch (actually two of=
 them) that allows to work around the problem. The first approach looks for=
 the first network interface that is configured for broadcasting and sends =
the broadcast to its network broadcast address. This should be in conforman=
ce to the RFCs that leave it to the implementation whether to do the broadc=
ast on an arbitraty network interface or on all of them. In my second attem=
pt to tackle the problem I am looking in addition at the source address of =
the IP packet and try to find a network interface that is in the same local=
 network as the source IP address. The code changes in the second approach =
are probably a bit more hackish and might need some further testing.

If you are interested I can provide you with the changes. They are based on=
 10-stable or 11-stable as of not to long ago. As the to-be-patched sources=
 do not change a lot the patches should be applicable with no problems. Of =
course I (or rather my company) would like to see the bug fixed in the Free=
BSD sources and would be sympathetic to a review of the patches in the hope=
 to include them in the official sources.

Regards,
Wolfgang


________________________________

Follow HOB:

- HOB: http://www.hob.de/redirect/hob.html
- Xing: http://www.hob.de/redirect/xing.html
- LinkedIn: http://www.hob.de/redirect/linkedin.html
- HOBLink Mobile: http://www.hob.de/redirect/hoblinkmobile.html
- Facebook: http://www.hob.de/redirect/facebook.html
- Twitter: http://www.hob.de/redirect/twitter.html
- YouTube: http://www.hob.de/redirect/youtube.html
- E-Mail: http://www.hob.de/redirect/mail.html


HOB GmbH & Co. KG
Schwadermuehlstr. 3
D-90556 Cadolzburg

Geschaeftsfuehrung: Klaus Brandstaetter, Zoran Adamovic

AG Fuerth, HRA 5180
Steuer-Nr. 218/163/00107
USt-ID-Nr. DE 132747002

Komplementaerin HOB electronic Beteiligungs GmbH
AG Fuerth, HRB 3416



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?EC88118611AE564AB0B10C6A4569004D015C057C24>