From: Florian Westphal <fw@strlen.de>
To: Jan Engelhardt <jengelh@inai.de>
Cc: Florian Westphal <fw@strlen.de>,
Laura Garcia Liebana <nevola@gmail.com>,
netfilter-devel@vger.kernel.org
Subject: Re: [PATCH] nft: Add support for inverted bitwise value list
Date: Wed, 22 Jun 2016 19:13:08 +0200 [thread overview]
Message-ID: <20160622171308.GE10213@breakpoint.cc> (raw)
In-Reply-To: <alpine.LSU.2.20.1606221847340.7827@nerf40.vanv.qr>
Jan Engelhardt <jengelh@inai.de> wrote:
>
> On Wednesday 2016-06-22 18:14, Florian Westphal wrote:
> >Laura Garcia Liebana <nevola@gmail.com> wrote:
> >> Add support for inverted state and status bitwise value list required in the
> >> ct match.
> >>
> >> Before this patch, nft didn't support the rule:
> >>
> >> $ nft add rule ip filter INPUT ct state != new,related counter accept
> >> <cmdline>:1:41-41: Error: syntax error, unexpected comma, expecting end of file or newline or semicolon
> >> add rule ip filter INPUT ct state != new,related counter accept
> > ^
> >I don't like nft foo,bar syntax since
> >
> >'state new,related' looks a lot like 'state { new, related }' but its not the same...
>
> What is the difference? More specifically, why is there a difference?
state { new, related } asks nft to perform a lookup in an anonymous set with the
key values new and related and check if there is a matching key.
> That appears to be a bad pitfall for users. (And as such, choosing
> different symbols like the pipe symbol does not cure the issue of
> confusion.)
The | already works, and in fact 'state new|related' is displayed as
'state new, related'.
state { new | related } would ask nft to perform a lookup in anonymous
set, but that set would have just one value, namely the result of '4|8': 12.
next prev parent reply other threads:[~2016-06-22 17:13 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-22 15:49 [PATCH] nft: Add support for inverted bitwise value list Laura Garcia Liebana
2016-06-22 16:14 ` Florian Westphal
2016-06-22 16:56 ` Jan Engelhardt
2016-06-22 17:13 ` Florian Westphal [this message]
2016-06-22 18:20 ` Pablo Neira Ayuso
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=20160622171308.GE10213@breakpoint.cc \
--to=fw@strlen.de \
--cc=jengelh@inai.de \
--cc=netfilter-devel@vger.kernel.org \
--cc=nevola@gmail.com \
/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.