lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aK8_i-_-Kmbozl0H@strlen.de>
Date: Wed, 27 Aug 2025 19:25:31 +0200
From: Florian Westphal <fw@...len.de>
To: Fabian Bläse <fabian@...ese.de>
Cc: netdev@...r.kernel.org, netfilter-devel@...r.kernel.org,
	"Jason A. Donenfeld" <Jason@...c4.com>
Subject: Re: [PATCH v2] icmp: fix icmp_ndo_send address translation for reply
 direction

Fabian Bläse <fabian@...ese.de> wrote:
> To avoid unnecessary translations, I suggested the direction-specific checks.
> Another option is to simplify them to:
> 
>      if (!(ct->status & IPS_NAT_MASK)) { … }

Yes, you can update the test from
        if (!ct || !(ct->status & IPS_SRC_NAT)) {

to
        if (!ct || !(ct->status & IPS_NAT_MASK)) {

Not related to your change:

I suspect there is a very small risk that kcsan could report a data
race here, given ct->status can be modified on other CPU.

But maybe, while at it, replace this with
READ_ONCE(ct->status) & ...

> Correct — the change not only fixes SNAT-in-reply handling, but also adds
> proper handling for DNAT in the reply direction, which was missing entirely.
> I will update the commit message to reflect this.

Thanks!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ