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: <CANn89iL+nXCD7465Q19mpT8avL1MZDr7o9fVi6U1C7YjpTOZug@mail.gmail.com>
Date: Tue, 29 Oct 2024 09:37:34 +0100
From: Eric Dumazet <edumazet@...gle.com>
To: Kuniyuki Iwashima <kuniyu@...zon.com>
Cc: "David S. Miller" <davem@...emloft.net>, Jakub Kicinski <kuba@...nel.org>, 
	Paolo Abeni <pabeni@...hat.com>, Ignat Korchagin <ignat@...udflare.com>, 
	Kuniyuki Iwashima <kuni1840@...il.com>, netdev@...r.kernel.org
Subject: Re: [PATCH v2 net-next] socket: Print pf->create() when it does not
 clear sock->sk on failure.

On Thu, Oct 24, 2024 at 10:15 PM Kuniyuki Iwashima <kuniyu@...zon.com> wrote:
>
> I suggested to put DEBUG_NET_WARN_ON_ONCE() in __sock_create() to
> catch possible use-after-free.
>
> But the warning itself was not useful because our interest is in
> the callee than the caller.
>
> Let's define DEBUG_NET_WARN_ONCE() and print the name of pf->create()
> and the socket identifier.
>
> While at it, we enclose DEBUG_NET_WARN_ON_ONCE() in parentheses too
> to avoid a checkpatch error.
>
> Note that %pf or %pF were obsoleted and will be removed later as per
> comment in lib/vsprintf.c.
>
> Link: https://lore.kernel.org/netdev/202410231427.633734b3-lkp@intel.com/
> Signed-off-by: Kuniyuki Iwashima <kuniyu@...zon.com>
> ---

Reviewed-by: Eric Dumazet <edumazet@...gle.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ