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]
Message-ID: <CAAVpQUCAPchBjAr3_S03ieKHvGBQmW+c2g7+QyeSCSEEvxW8XQ@mail.gmail.com>
Date: Tue, 26 Aug 2025 23:47:51 -0700
From: Kuniyuki Iwashima <kuniyu@...gle.com>
To: Takamitsu Iwai <takamitz@...zon.co.jp>
Cc: linux-hams@...r.kernel.org, netdev@...r.kernel.org, 
	"David S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>, 
	Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>, Simon Horman <horms@...nel.org>, 
	Kohei Enju <enjuk@...zon.com>, Ingo Molnar <mingo@...nel.org>, 
	Thomas Gleixner <tglx@...utronix.de>, Jesper Dangaard Brouer <hawk@...nel.org>, 
	Nikita Zhandarovich <n.zhandarovich@...tech.ru>
Subject: Re: [PATCH v2 net 2/3] net: rose: convert 'use' field to refcount_t

On Sat, Aug 23, 2025 at 2:01 AM Takamitsu Iwai <takamitz@...zon.co.jp> wrote:
>
> The 'use' field in struct rose_neigh is used as a reference counter but
> lacks atomicity. This can lead to race conditions where a rose_neigh
> structure is freed while still being referenced by other code paths.
>
> For example, when rose_neigh->use becomes zero during an ioctl operation
> via rose_rt_ioctl(), the structure may be removed while its timer is
> still active, potentially causing use-after-free issues.
>
> This patch changes the type of 'use' from unsigned short to refcount_t and
> updates all code paths to use rose_neigh_hold() and rose_neigh_put() which
> operate reference counts atomically.
>
> Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
> Signed-off-by: Takamitsu Iwai <takamitz@...zon.co.jp>

Reviewed-by: Kuniyuki Iwashima <kuniyu@...gle.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ