Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 13 Oct 2016 15:40:40 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-bugs@FreeBSD.org
Subject:   [Bug 213452] [patch] [ipfw] add support for ipfw ngtee/netgraph actions at layer-2
Message-ID:  <bug-213452-8@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D213452

            Bug ID: 213452
           Summary: [patch] [ipfw] add support for ipfw ngtee/netgraph
                    actions at layer-2
           Product: Base System
           Version: 11.0-STABLE
          Hardware: Any
                OS: Any
            Status: New
          Keywords: patch
          Severity: Affects Some People
          Priority: ---
         Component: kern
          Assignee: freebsd-bugs@FreeBSD.org
          Reporter: ports@grosbein.net
          Keywords: patch

Created attachment 175712
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D175712&action=
=3Dedit
add support for ngtee/netgraph ipfw actions for layer-2 frames

Currently, kernel part of ipfw for layer-2 (ethernet frames) does not suppo=
rt
and ignores ipfw rules other than "pass", "deny" and dummynet-related.
Any other rule acts like "pass" for layer-2 packets. That prevents us from
selective copying of Ethernet frames for remote traffic analyzing/mirroring=
=20
purposes.

Assume, we have ethernet-like interface (NIC, vlan, tap etc.) and we need
to selectively mirror some frames there. In case of vlan900 and assuming
ng_ipfw(4) netgraph node has a hook named "900" attached to "lower" hook
of vlan900's ng_ether(4) node, that would be as simple as:

ipfw add ngtee 900 ip from any to 8.8.8.8 layer2 out xmit igb0

Attached patch makes it work.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



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