[ovs-git] Open vSwitch: lib/netdev-linux.c: Prevent receiving of sent packets (master)

dev at openvswitch.org dev at openvswitch.org
Thu Jun 13 21:43:56 UTC 2013


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Open vSwitch".

The branch, master has been updated
       via  32383c3bd064fb87ec2b366569ba1185698c2e6d (commit)
      from  ddd3c9755d5fb1606445a72fb5f25e615518a162 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 32383c3bd064fb87ec2b366569ba1185698c2e6d
Diffs: http://openvswitch.org/cgi-bin/gitweb.cgi?p=openvswitch;a=commitdiff;h=32383c3bd064fb87ec2b366569ba1185698c2e6d
Author: Murphy McCauley <murphy.mccauley at gmail.com>
		
lib/netdev-linux.c: Prevent receiving of sent packets
		
Commit 796223f5 (netdev: Add new "struct netdev_rx" for capturing packets
from a netdev) refactored send and receive into separate netdevs.  As a
result, send and receive now use different socket descriptors (except for tap
interfaces which are treated specially).  An unintended side effect was that
all sent packets are looped back and received, which had previously been
avoided as the kernel specifically prevents this from happening on a single
socket descriptor.

To resolve the situation, a socket filter is added to the receive socket
so that it only accepts inbound packets.

Simon Horman co-discovered and initially reported this issue.

Signed-off-by: Murphy McCauley <murphy.mccauley at gmail.com>
Signed-off-by: Ben Pfaff <blp at nicira.com>
Tested-by: Simon Horman <horms at verge.net.au>
Reviewed-by: Simon Horman <horms at verge.net.au>


-----------------------------------------------------------------------

Summary of changes:
 AUTHORS                     |    2 +-
 include/sparse/sys/socket.h |    5 +++--
 lib/netdev-linux.c          |   22 +++++++++++++++++++++-
 3 files changed, 25 insertions(+), 4 deletions(-)


hooks/post-receive
-- 
Open vSwitch



More information about the git mailing list