From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ani Sinha Subject: Re: tcpdump's capture filter: "vlan" doesn't match Date: Thu, 16 Oct 2014 16:39:07 -0700 Message-ID: References: <543F616C.5040801@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Cc: Daniel Borkmann , "netdev@vger.kernel.org" , John Fastabend , =?UTF-8?B?TWljaGHFgiBNaXJvc8WCYXc=?= , Jiri Pirko , Ben Hutchings , Atzm Watanabe , Patrick McHardy , Jesse Gross , Michael Richardson , Ani Sinha , fenner To: Lukas Tribus Return-path: Received: from mail-ig0-f173.google.com ([209.85.213.173]:53101 "EHLO mail-ig0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751033AbaJPXj2 (ORCPT ); Thu, 16 Oct 2014 19:39:28 -0400 Received: by mail-ig0-f173.google.com with SMTP id h18so608968igc.12 for ; Thu, 16 Oct 2014 16:39:27 -0700 (PDT) In-Reply-To: Sender: netdev-owner@vger.kernel.org List-ID: +fenner. I had spent some considerable time in the past looking into this and proposing a patch : http://seclists.org/tcpdump/2013/q1/0 However, there was no feedback and I got sucked into a different project and this work fell through the cracks. If someone else picks it up, I will be glad to help/lend a hand. Cheers, ani On Thu, Oct 16, 2014 at 4:25 PM, Lukas Tribus wrote: >>> Isn't disabling rx-vlan-offloading supposed to remedy those problems? >> >> There were some discussions on this in the past e.g. [1]. We have >> SKF_AD_VLAN_TAG and SKF_AD_VLAN_TAG_PRESENT for the BPF filter on >> this, but libpcap is currently not making use of any of them. >> >> [1] http://thread.gmane.org/gmane.linux.network/247947 > > Thanks for the link. I see the situation is unfortunate and although those > new BPF filters in the kernel may fix the actual filtering problem, one > thing seems to remain impossible: disabling all this kernel magic and > passing the frame as-is to libpcap without interception (avoiding any > kind of artificial header reconstruction). > > How is the situation with netsniff-ng anyway? Does it use vlan BPF filter > in the kernel? > > > > Regards, > > Lukas > >