Ethernet Bridge development
 help / color / mirror / Atom feed
From: Rob Boucher <robsgreen325@gmail.com>
To: bridge@lists.osdl.org
Subject: [Bridge] PF_PACKET socket
Date: Fri, 8 Apr 2005 08:32:02 -0500	[thread overview]
Message-ID: <807abdd20504080632711e6232@mail.gmail.com> (raw)

From the archives it looks like there may be some knowledge in this area... 
2.4.20 kernel

I have 2 network interfaces eth0 & eth1 connected via bridge br0. eth0
and eth1 do not have IPs, br0 may or may not have an IP. Not planning
on using ebtables package to solve this problem.....

Here is the first question...

If a user space process wants to intercept packets entering eth0 for a
specific protocol, ETH_P_802_2 for example, (basically any case where
a packet hander is installed into the ptype_base[] table in dev.c,
AFTER the bridge code entry point). How do I bind the user space
socket to guarantee that it will receive the ETH_P_802_2 frames
received/posted by eth0.

It looks to me like: if the socket is created and then bound to eth0
it will never see any frames of type ETH_P_802_2 when a bridge is
place. Is this correct?

What should happen when the PF_PACKET socket is bound to br0? Should I
expect to see 802.2 packets from the bridge? Will all the packets pass
by undetected? Will the bridge only pass the packets up if an IP
address is assigned to br0?
  
Another question, again w/o ebtables....
Is there a way with PF_PACKET to intercept a certain protocol type
before it enters the bridge, pass it to the PF_PACKET handler
completely consuming the frame. Thus, causing the frame to be consumed
by the localhost and not bridged?

Thanks!!
Rob

                 reply	other threads:[~2005-04-08 13:32 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=807abdd20504080632711e6232@mail.gmail.com \
    --to=robsgreen325@gmail.com \
    --cc=bridge@lists.osdl.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox