Use SO_BINDTODEVICE to bind to a specific interface.
Under Linux, the socket will receive all packets for a given multicast address, from any interface, even if the interface address is specified. SO_BINDTODEVICE requires the CAP_NET_ADMIN capability. Patch courtesy of Benjamin Cohen bcohen AT openheadend DOT tv.
Showing with 20 additions and 0 deletions