CVE-2026-99154: scsi: libiscsi: Reject a negative task index from parse_pdu_itt
From: Greg Kroah-Hartman <[email protected]>
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
scsi: libiscsi: Reject a negative task index from parse_pdu_itt
A transport that implements parse_pdu_itt hands libiscsi an index taken from the PDU, and both lookups bound it from above only:
if (i >= session->cmds_max)
i and cmds_max are both int, so a negative index passes and session->cmds[i] is read from before the array.
be2iscsi produces one. beiscsi_parse_pdu() assigns the raw tag,
*index = (int)itt;
and beiscsi_complete_pdu() forwards an unsolicited NOP-In from the hardware async ring without replacing its ITT, so the value is the target's. It also reports the session's own age rather than the one in the tag, which leaves the age comparison in iscsi_verify_itt() with nothing to reject.
Bound the index from below in both lookups.
The Linux kernel CVE team has assigned CVE-2026-99154 to this issue.
Affected and fixed versions
===========================
Issue introduced in 2.6.33 with commit bfead3b2cb4607c71831423c3ee97d22cd0c9dcb and fixed in 6.18.59 with commit 6cadfa6f1f5896632d4223d3b7addb2a29fea74e Issue introduced in 2.6.33 with commit bfead3b2cb4607c71831423c3ee97d22cd0c9dcb and fixed in 7.2.13 with commit 35b60549a956237488c89a2d85352e026e7d55b7 Issue introduced in 2.6.33 with commit bfead3b2cb4607c71831423c3ee97d22cd0c9dcb and fixed in 7.3 with commit 8ee2a09a1dbb257c9e828ad2497f8e4832dfb142
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-99154
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/libiscsi.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/6cadfa6f1f5896632d4223d3b7addb2a29fea74e https://git.kernel.org/stable/c/35b60549a956237488c89a2d85352e026e7d55b7 https://git.kernel.org/stable/c/8ee2a09a1dbb257c9e828ad2497f8e4832dfb142