gvisor/pkg
Chris Kuiper 4874525161 Implement proper local broadcast behavior
The behavior for sending and receiving local broadcast (255.255.255.255)
traffic is as follows:

Outgoing
--------
* A broadcast packet sent on a socket that is bound to an interface goes out
  that interface
* A broadcast packet sent on an unbound socket follows the route table to
  select the outgoing interface
  + if an explicit route entry exists for 255.255.255.255/32, use that one
  + else use the default route
* Broadcast packets are looped back and delivered following the rules for
  incoming packets (see next). This is the same behavior as for multicast
  packets, except that it cannot be disabled via sockopt.

Incoming
--------
* Sockets wishing to receive broadcast packets must bind to either INADDR_ANY
  (0.0.0.0) or INADDR_BROADCAST (255.255.255.255). No other socket receives
  broadcast packets.
* Broadcast packets are multiplexed to all sockets matching it. This is the
  same behavior as for multicast packets.
* A socket can bind to 255.255.255.255:<port> and then receive its own
  broadcast packets sent to 255.255.255.255:<port>

In addition, this change implicitly fixes an issue with multicast reception. If
two sockets want to receive a given multicast stream and one is bound to ANY
while the other is bound to the multicast address, only one of them will
receive the traffic.

PiperOrigin-RevId: 272792377
2019-10-03 19:31:35 -07:00
..
abi Signalfd support 2019-09-18 15:16:42 -07:00
amutex Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
atomicbitops Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
binary Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
bits Enable pkg/bits support on arm64. 2019-09-24 07:03:19 +00:00
bpf Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
compressio Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
control Update canonical repository. 2019-06-13 16:50:15 -07:00
cpuid Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
eventchannel Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
fd Merge pull request #765 from trailofbits:uds_support 2019-09-25 16:44:22 -07:00
fdchannel Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
fdnotifier Change syscall.EPOLLET to unix.EPOLLET 2019-08-05 23:10:08 +00:00
flipcall Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
fspath Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
gate Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
ilist Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
linewriter Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
log Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
memutil Update canonical repository. 2019-06-13 16:50:15 -07:00
metric internal BUILD file cleanup. 2019-09-23 08:25:13 -07:00
p9 Add test for concurrent reads and writes. 2019-09-23 16:44:30 -07:00
procid Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
rand Update canonical repository. 2019-06-13 16:50:15 -07:00
refs Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
seccomp gvisor: change syscall.RawSyscall to syscall.RawSyscall6 where required 2019-09-24 23:47:42 -07:00
secio Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
segment Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
sentry Don't report partialResult errors from sendfile 2019-10-03 13:38:30 -07:00
sleep Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
state Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
syserr netstack/udp: connect with the AF_UNSPEC address family means disconnect 2019-07-03 14:19:02 -07:00
syserror Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
tcpip Implement proper local broadcast behavior 2019-10-03 19:31:35 -07:00
tmutex Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
unet Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
urpc Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00
waiter Remove go_test from go_stateify and go_marshal 2019-09-12 15:10:17 -07:00