From: Florian Westphal <fw@strlen.de>
To: michael-dev <michael-dev@fami-braun.de>
Cc: netfilter-devel@vger.kernel.org
Subject: Re: nftables matching gratuitous arp
Date: Wed, 21 Aug 2019 23:00:30 +0200 [thread overview]
Message-ID: <20190821210030.GC20113@breakpoint.cc> (raw)
In-Reply-To: <c81c933d181adbfdad94057569501d35@fami-braun.de>
michael-dev <michael-dev@fami-braun.de> wrote:
> I'm trying to match gratuitous arp with nftables. I've tried
> > nft add rule bridge filter somechain arp saddr ip == arp daddr ip
>
> but nft (some commits before 0.9.2) says:
> > Error: syntax error, unexpected daddr, expecting end of file or newline
> > or semicolon
> > add rule bridge filter FORWARD arp saddr ip == arp daddr ip
> ^^^^^
> Looking at the description of the netlink protocol, it looks like two loads
> and a cmp of both registers would do it.
Yes, but cmp doesn't support this, see nft_cmp_eval() in
net/netfilter/nft_cmp.c .
The compare occurs between a register and a immediate value.
Having cmp (and also binops) involving a second sreg would be
good to have.
prev parent reply other threads:[~2019-08-21 21:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-21 19:29 nftables matching gratuitous arp michael-dev
2019-08-21 21:00 ` Florian Westphal [this message]
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=20190821210030.GC20113@breakpoint.cc \
--to=fw@strlen.de \
--cc=michael-dev@fami-braun.de \
--cc=netfilter-devel@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.