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] [thread-next>] [day] [month] [year] [list]
Date: Tue, 10 Oct 2023 17:19:03 +0200
From: Simon Horman <horms@...nel.org>
To: Köry Maincent <kory.maincent@...tlin.com>
Cc: Michal Kubecek <mkubecek@...e.cz>,
	"David S. Miller" <davem@...emloft.net>, netdev@...r.kernel.org,
	linux-kernel@...r.kernel.org,
	Maxime Chevallier <maxime.chevallier@...tlin.com>,
	thomas.petazzoni@...tlin.com, Eric Dumazet <edumazet@...gle.com>,
	Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>
Subject: Re: [PATCH net v3 1/1] ethtool: Fix mod state of verbose no_mask
 bitset

On Mon, Oct 09, 2023 at 03:36:45PM +0200, Köry Maincent wrote:
> From: Kory Maincent <kory.maincent@...tlin.com>
> 
> A bitset without mask in a _SET request means we want exactly the bits in
> the bitset to be set. This works correctly for compact format but when
> verbose format is parsed, ethnl_update_bitset32_verbose() only sets the
> bits present in the request bitset but does not clear the rest. The commit
> 6699170376ab fixes this issue by clearing the whole target bitmap before we
> start iterating. The solution proposed brought an issue with the behavior
> of the mod variable. As the bitset is always cleared the old val will
> always differ to the new val.
> 
> Fix it by adding a new temporary variable which save the state of the old
> bitmap.
> 
> Fixes: 6699170376ab ("ethtool: fix application of verbose no_mask bitset")
> Signed-off-by: Kory Maincent <kory.maincent@...tlin.com>
> ---
> 
> Changes in v2:
> - Fix the allocated size.
> 
> Changes in v3:
> - Add comment.
> - Updated variable naming.
> - Add orig_bitmap variable to avoid n_mask condition in the
>   nla_for_each_nested() loop.

Hi Köry,

thanks for the updates. This one looks good to me.

Reviewed-by: Simon Horman <horms@...nel.org>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ