Thread (13 messages) 13 messages, 3 authors, 2013-08-02

Re: How do I receive vlan tags on an AF_PACKET socket in 3.4 kernel?

From: Eric Dumazet <hidden>
Date: 2013-07-31 15:09:33

On Wed, 2013-07-31 at 16:42 +0200, Daniel Borkmann wrote:
You can use bpfc (git://github.com/borkmann/netsniff-ng.git), it also has
an extensive man page. That should probably do it:

$ cat foo
ld vlant
jneq #4094, drop
ret #-1
drop: ret #0

$ bpfc foo
{ 0x20, 0, 0, 0xfffff02c },
{ 0x15, 0, 1, 0x00000ffe },
{ 0x6, 0, 0, 0xffffffff },
{ 0x6, 0, 0, 0x00000000 },
Thanks Daniel.

If the load of this BPF fails (because its an old kernel), then load
your old filter.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help