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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZQhButkhI8K6cduD@gondor.apana.org.au>
Date: Mon, 18 Sep 2023 20:25:30 +0800
From: Herbert Xu <herbert@...dor.apana.org.au>
To: Pablo Neira Ayuso <pablo@...filter.org>
Cc: Alexander Aring <aahringo@...hat.com>,
	Network Development <netdev@...r.kernel.org>, kadlec@...filter.org,
	fw@...len.de, gfs2@...ts.linux.dev,
	David Teigland <teigland@...hat.com>, tgraf@...g.ch
Subject: Re: nft_rhash_walk, rhashtable and resize event

On Mon, Sep 18, 2023 at 01:59:47PM +0200, Pablo Neira Ayuso wrote:
>
> One more question: this walk might miss entries but may it also
> duplicate the same entries?

It depends on what happens during the walk.  If you're lucky
and no resize event occurs during the walk, then you won't miss
any entries or see duplicates.

When a resize event does occur, then we will tell you that it
happened by returning EAGAIN.  It means that you should start
from the beginning and redo the whole walk.  If you do that
then you won't miss anything (although, you may never finish
if the table keeps getting resized).

But obviously duplicates will occur if you take this approach.

> I will work on a patch to update netfilter clients for this code to
> use a rcu linked list.

Sounds good!

Thanks,
-- 
Email: Herbert Xu <herbert@...dor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ