All of lore.kernel.org
 help / color / mirror / Atom feed
From: Florian Westphal <fw@strlen.de>
To: Pablo Neira Ayuso <pablo@netfilter.org>
Cc: Florian Westphal <fw@strlen.de>,
	netfilter-devel@vger.kernel.org, dvyukov@google.com
Subject: Re: [PATCH nf,v2] netfilter: nftables: accept all dummy chain when table is dormant
Date: Fri, 21 May 2021 11:28:09 +0200	[thread overview]
Message-ID: <20210521092809.GC3559@breakpoint.cc> (raw)
In-Reply-To: <20210520225054.GA31069@salvia>

Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> On Wed, May 19, 2021 at 08:34:04PM +0200, Florian Westphal wrote:
> > ... but that is doable in the sense that unregister can't fail.
> 
> Right, but adding "unregister hooks" to the abort path breaks a
> different scenario. This might unregister a hook that, because of a later
> wake-up action, needs to stay there, because you cannot call register
> a hook from the abort path, it's a bit of a whac-a-mole game.

Argh, indeed.  We'd have to re-scan the transaction log during
preparation phase for each dormant on/off and chain add/delete to
see if the action un-does an earlier pending one, then remove both
if they cancel each other.

> > I guess dormat tables are an exception and not the norm, so maybe
> > unfounded concern.
> 
> You are right that this approach incurs in the hook evaluation penalty
> from the packet path. But I don't think there's a need to optimize
> this feature at this stage

Ok, I dislike optimizing too early as well.

> So I'm just inclined to keep it simple while making sure that any
> possible (silly) robot-generated sequence with this toggle works fine.

Ok, lets use your approach then.

      reply	other threads:[~2021-05-21  9:28 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-19 10:14 [PATCH nf,v2] netfilter: nftables: accept all dummy chain when table is dormant Pablo Neira Ayuso
2021-05-19 12:15 ` Florian Westphal
2021-05-19 15:56   ` Pablo Neira Ayuso
2021-05-19 18:34     ` Florian Westphal
2021-05-20 22:50       ` Pablo Neira Ayuso
2021-05-21  9:28         ` 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=20210521092809.GC3559@breakpoint.cc \
    --to=fw@strlen.de \
    --cc=dvyukov@google.com \
    --cc=netfilter-devel@vger.kernel.org \
    --cc=pablo@netfilter.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.