All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pablo Neira Ayuso <pablo@netfilter.org>
To: Adrian Moisey <adrian@changeover.za.net>
Cc: netfilter-devel@vger.kernel.org
Subject: Re: [PATCH nft] netlink_linearize: size nat register allocation by address expression
Date: Thu, 20 Aug 2026 13:15:57 +0200	[thread overview]
Message-ID: <aobh7eQw-eqF1iQI@chamomile> (raw)
In-Reply-To: <20260806185020.95154-1-adrian@changeover.za.net>

On Thu, Aug 06, 2026 at 08:50:20PM +0200, Adrian Moisey wrote:
> nat statements with a literal concatenation of address and port, e.g.
> 
>   dnat ip6 addr . port to fd00:10:244::4 . 6443
> 
> allocated a fixed 128-bit register block for the address, but the ip6
> address . port concatenation is 144 bits (5 registers), so
> netlink_gen_concat overran into unallocated registers and hit the
> assertion 'dreg < ctx->reg_low' in netlink_gen_expr. IPv4 escaped by
> luck since its 48-bit concatenation fits into the padded block.
> 
> Allocate the register based on the address expression instead, which
> sizes by expr->len for concatenations, and add the matching
> release_register() call. Extend the nat_addr_port test with literal
> concatenation rules for ip and ip6.

Applied, thanks

      reply	other threads:[~2026-08-20 11:16 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-06 18:50 [PATCH nft] netlink_linearize: size nat register allocation by address expression Adrian Moisey
2026-08-20 11:15 ` 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=aobh7eQw-eqF1iQI@chamomile \
    --to=pablo@netfilter.org \
    --cc=adrian@changeover.za.net \
    --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.