Skip to contentSkip to conversation

CVE-2025-38238: scsi: fnic: Fix crash in fnic_wq_cmpl_handler when FDMI times out

DISCUSSION Greg Kroah-Hartman 1 participant 1 message Jul 9, 2025

lore
Share & tools
lore
#0 lore raw

From: Greg Kroah-Hartman <[email protected]>

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

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

scsi: fnic: Fix crash in fnic_wq_cmpl_handler when FDMI times out

When both the RHBA and RPA FDMI requests time out, fnic reuses a frame to send ABTS for each of them. On send completion, this causes an attempt to free the same frame twice that leads to a crash.

Fix crash by allocating separate frames for RHBA and RPA, and modify ABTS logic accordingly.

Tested by checking MDS for FDMI information.

Tested by using instrumented driver to:

- Drop PLOGI response
- Drop RHBA response
- Drop RPA response
- Drop RHBA and RPA response
- Drop PLOGI response + ABTS response
- Drop RHBA response + ABTS response
- Drop RPA response + ABTS response
- Drop RHBA and RPA response + ABTS response for both of them

The Linux kernel CVE team has assigned CVE-2025-38238 to this issue.

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

	Issue introduced in 6.14 with commit 09c1e6ab4ab2a107d96f119950dc330e446dc2b0 and fixed in 6.15.5 with commit 09679e9abedfbc5a2590759a1a7893c1c26e6044
	Issue introduced in 6.14 with commit 09c1e6ab4ab2a107d96f119950dc330e446dc2b0 and fixed in 6.16-rc4 with commit a35b29bdedb4d2ae3160d4d6684a6f1ecd9ca7c2

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-2025-38238

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/scsi/fnic/fdls_disc.c
drivers/scsi/fnic/fnic.h
drivers/scsi/fnic/fnic_fdls.h

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/09679e9abedfbc5a2590759a1a7893c1c26e6044
	https://git.kernel.org/stable/c/a35b29bdedb4d2ae3160d4d6684a6f1ecd9ca7c2