CVE-2026-74385: nvmet-tcp: check return value of nvmet_tcp_set_queue_sock

Greg Kroah-Hartman <[email protected]>
Newsgroups org.kernel.vger.linux-cve-announce
Message-ID <2026081506-CVE-2026-74385-b03d@gregkh>
From: Greg Kroah-Hartman <[email protected]>

Description
===========

In the Linux kernel, the following vulnerability has been resolved:

nvmet-tcp: check return value of nvmet_tcp_set_queue_sock

The return value of nvmet_tcp_set_queue_sock() is currently ignored in
nvmet_tcp_tls_handshake_done(). If it fails (e.g., due to the socket
not being in TCP_ESTABLISHED state), the socket callbacks will not be
properly set, leading to queue and socket leakage.

Fix this by capturing the return value and calling
nvmet_tcp_schedule_release_queue() on failure to ensure proper cleanup.

The Linux kernel CVE team has assigned CVE-2026-74385 to this issue.


Affected and fixed versions
===========================

	Issue introduced in 6.7 with commit 675b453e024154dd547921c6e6d5b58747ba7e0e and fixed in 6.18.40 with commit cba2ee57fd302727aea7d41e9d9cd0969f5df0fb
	Issue introduced in 6.7 with commit 675b453e024154dd547921c6e6d5b58747ba7e0e and fixed in 7.1.5 with commit 22aa70f9a0544643ec37d442b6fcb1833d804462
	Issue introduced in 6.7 with commit 675b453e024154dd547921c6e6d5b58747ba7e0e and fixed in 7.2-rc1 with commit 7ef789703e2b91775dcb36b2efa46325be31a2a0

Please see https://www.kernel.org for a full list of currently supported
kernel versions by the kernel community.

Unaffected versions might change over time as fixes are backported to
older supported kernel versions.  The official CVE entry at
	https://cve.org/CVERecord/?id=CVE-2026-74385
will be updated if fixes are backported, please check that for the most
up to date information about this issue.


Affected files
==============

The file(s) affected by this issue are:
	drivers/nvme/target/tcp.c


Mitigation
==========

The Linux kernel CVE team recommends that you update to the latest
stable kernel version for this, and many other bugfixes.  Individual
changes are never tested alone, but rather are part of a larger kernel
release.  Cherry-picking individual commits is not recommended or
supported by the Linux kernel community at all.  If however, updating to
the latest release is impossible, the individual changes to resolve this
issue can be found at these commits:
	https://git.kernel.org/stable/c/cba2ee57fd302727aea7d41e9d9cd0969f5df0fb
	https://git.kernel.org/stable/c/22aa70f9a0544643ec37d442b6fcb1833d804462
	https://git.kernel.org/stable/c/7ef789703e2b91775dcb36b2efa46325be31a2a0
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.