All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pablo Neira Ayuso <pablo@netfilter.org>
To: Florian Westphal <fw@strlen.de>
Cc: netfilter-devel@vger.kernel.org
Subject: Re: [RFC nf 0/2] netfilter: add restrictions/validations for packet rewrites
Date: Thu, 4 Jun 2026 08:17:04 +0200	[thread overview]
Message-ID: <aiEYYP0PaWOkbRgh@chamomile> (raw)
In-Reply-To: <aiC0lYKyD5UDQgLS@strlen.de>

On Thu, Jun 04, 2026 at 01:11:17AM +0200, Florian Westphal wrote:
> Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> > > If anyone is breaking with ilegals field, they should come here to
> > > explain? Data plane validation might look safer ... but it will just
> > > drop packets and it will take a bit more time to the user to debug.
> > > But your approach is more conservative, it just leave the packet
> > > untouch, so it is basically ignoring the invalid mangling.
> 
> Yes, ignore resp. BREAK verdict.
> 
> > Hm. Actually, it is harder than it seems to do this from control plane
> > because dscp needs to deal with bitwise to ensure that ihl and version
> > are not modified.
> 
> Yes, there are cases like those where control plane valition is not
> possible.  I will address the AI comments and resubmit w.o. RFC tag.

It should be possible with some sort of register tracking. At ruleset
load time, the hardware offload infrastructure already do something
similar, and I added infrastructure for this for a different purpose.

But this can be done later, the datapath checks now should be fine to
start with.

      reply	other threads:[~2026-06-04  6:17 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-27 12:11 [RFC nf 0/2] netfilter: add restrictions/validations for packet rewrites Florian Westphal
2026-05-27 12:11 ` [RFC nf 1/2] netfilter: nfnetlink_queue: restrict writes to network header Florian Westphal
2026-05-27 12:11 ` [RFC nf 2/2] netfilter: nftables: restrict linklayer and network header writes Florian Westphal
2026-06-03 22:33 ` [RFC nf 0/2] netfilter: add restrictions/validations for packet rewrites Pablo Neira Ayuso
2026-06-03 22:42   ` Pablo Neira Ayuso
2026-06-03 23:11     ` Florian Westphal
2026-06-04  6:17       ` Pablo Neira Ayuso [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=aiEYYP0PaWOkbRgh@chamomile \
    --to=pablo@netfilter.org \
    --cc=fw@strlen.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.