netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Phil Sutter <phil@nwl.cc>
To: Stefano Brivio <sbrivio@redhat.com>
Cc: Pablo Neira Ayuso <pablo@netfilter.org>, netfilter-devel@vger.kernel.org
Subject: Re: [PATCH nf 0/2] nft_set_pipapo: Fix crash due to dangling entries in mapping table
Date: Fri, 21 Feb 2020 22:17:04 +0100	[thread overview]
Message-ID: <20200221211704.GM20005@orbyte.nwl.cc> (raw)
In-Reply-To: <cover.1582250437.git.sbrivio@redhat.com>

Hi Stefano,

On Fri, Feb 21, 2020 at 03:04:20AM +0100, Stefano Brivio wrote:
> Patch 1/2 fixes the issue recently reported by Phil on a sequence of
> add/flush/add operations, and patch 2/2 introduces a test case
> covering that.

This fixes my test case, thanks!

I found another problem, but it's maybe on user space side (and not a
crash this time ;):

| # nft add table t
| # nft add set t s '{ type inet_service . inet_service ; flags interval ; }
| # nft add element t s '{ 20-30 . 40, 25-35 . 40 }'
| # nft list ruleset
| table ip t {
| 	set s {
| 		type inet_service . inet_service
| 		flags interval
| 		elements = { 20-30 . 40 }
| 	}
| }

As you see, the second element disappears. It happens only if ranges
overlap and non-range parts are identical.

Looking at do_add_setelems(), set_to_intervals() should not be called
for concatenated ranges, although I *think* range merging happens only
there. So user space should cover for that already?! Still, it doesn't
work.

Cheers, Phil

  parent reply	other threads:[~2020-02-21 21:17 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-21  2:04 [PATCH nf 0/2] nft_set_pipapo: Fix crash due to dangling entries in mapping table Stefano Brivio
2020-02-21  2:04 ` [PATCH nf 1/2] nft_set_pipapo: Actually fetch key data in nft_pipapo_remove() Stefano Brivio
2020-02-21  2:04 ` [PATCH nf 2/2] selftests: nft_concat_range: Add test for reported add/flush/add issue Stefano Brivio
2020-02-21 21:17 ` Phil Sutter [this message]
2020-02-21 22:22   ` [PATCH nf 0/2] nft_set_pipapo: Fix crash due to dangling entries in mapping table Stefano Brivio
2020-02-22  1:19     ` Phil Sutter
2020-02-23 21:22       ` Stefano Brivio
2020-02-25 12:39         ` Pablo Neira Ayuso
2020-02-25 12:45           ` Stefano Brivio
2020-02-25 13:13           ` Stefano Brivio
2020-02-25 13:42             ` Pablo Neira Ayuso
2020-02-25 14:34               ` Stefano Brivio
2020-02-25 18:48                 ` Phil Sutter
2020-02-25 19:33                   ` Stefano Brivio
2020-02-25 20:21                 ` Pablo Neira Ayuso
2020-02-25 20:38                   ` Stefano Brivio
2020-02-25 20:58                     ` Pablo Neira Ayuso
2020-02-26 10:58                       ` Pablo Neira Ayuso
2020-02-26 11:01                         ` Pablo Neira Ayuso
2020-02-26 11:02                         ` Stefano Brivio
2020-02-26 11:29                           ` Pablo Neira Ayuso
2020-02-26 11:36                             ` Stefano Brivio
2020-02-26 11:53                               ` Pablo Neira Ayuso
2020-02-26 10:59                       ` Stefano Brivio
2020-02-26 11:10                         ` Pablo Neira Ayuso
2020-02-26 11:19                           ` Stefano Brivio
2020-02-26 11:34                             ` Pablo Neira Ayuso
2020-02-26 11:39                               ` Stefano Brivio
2020-02-26 11:54                                 ` Stefano Brivio
2020-02-26 12:10                                   ` Pablo Neira Ayuso
2020-02-26 13:33 ` 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=20200221211704.GM20005@orbyte.nwl.cc \
    --to=phil@nwl.cc \
    --cc=netfilter-devel@vger.kernel.org \
    --cc=pablo@netfilter.org \
    --cc=sbrivio@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).