All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ian Bridges <icb@fastmail.org>
To: metze@samba.org
Cc: linux-cifs@vger.kernel.org, samba-technical@lists.samba.org,
	stable@vger.kernel.org, linkinjeon@kernel.org,
	senozhatsky@chromium.org, tom@talpey.com,
	chenxiaosong@chenxiaosong.com, sashiko-bot@kernel.org,
	Ian Bridges <icb@fastmail.org>
Subject: Re: [PATCH 2/2] smb: server: don't leak the smbdirect listener socket on errors
Date: Fri, 27 Nov 2026 14:51:15 -0600	[thread overview]
Message-ID: <20261127205115.1646407-1-icb@fastmail.org> (raw)
In-Reply-To: <17d7f96be20a7eb039cbb3833598f634d786a487.1795797772.git.metze@samba.org>

I tested this patch on ksmbd-for-next 3dcffd93d4da with KASAN and
kmemleak, using soft-RoCE. I started ksmbd ten times while another RDMA
CM listener held port 445, and ten times while one held port 5445. Each
start logged the failed bind. Without the patch, kmemleak reported the
listener socket and its rdma_cm id allocated in smb_direct_listen() as
leaked. With the patch it reported none. After the other listener was
gone, ksmbd listened again, and a Linux client mount over SMB Direct
read and wrote data correctly. KASAN reported nothing.

Reviewed-by: Ian Bridges <icb@fastmail.org>
Tested-by: Ian Bridges <icb@fastmail.org>

  reply	other threads:[~2026-11-27 20:51 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-27 16:48 [PATCH 0/2] smb: server: fix the nonce of encrypted responses and a listener leak Stefan Metzmacher
2026-11-27 16:48 ` [PATCH 1/2] smb: server: use a counter for the nonce of encrypted responses Stefan Metzmacher
2026-11-27 20:49   ` Ian Bridges
2026-11-28  0:23   ` Namjae Jeon
2026-11-27 16:48 ` [PATCH 2/2] smb: server: don't leak the smbdirect listener socket on errors Stefan Metzmacher
2026-11-27 20:51   ` Ian Bridges [this message]
2026-11-28  0:24   ` Namjae Jeon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261127205115.1646407-1-icb@fastmail.org \
    --to=icb@fastmail.org \
    --cc=chenxiaosong@chenxiaosong.com \
    --cc=linkinjeon@kernel.org \
    --cc=linux-cifs@vger.kernel.org \
    --cc=metze@samba.org \
    --cc=samba-technical@lists.samba.org \
    --cc=sashiko-bot@kernel.org \
    --cc=senozhatsky@chromium.org \
    --cc=stable@vger.kernel.org \
    --cc=tom@talpey.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.