CVE-2026-89858: scsi: qla2xxx: Bound image count in qla2x00_update_fru_versions()
From: Greg Kroah-Hartman <[email protected]>
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
scsi: qla2xxx: Bound image count in qla2x00_update_fru_versions()
qla2x00_update_fru_versions() copies the user-supplied BSG request into a fixed 256-byte stack buffer (bsg[DMA_POOL_SIZE]) and then iterates list->count times over the qla_image_version array embedded in that buffer, advancing the image pointer each iteration. count is taken directly from user input with no upper bound, while only (DMA_POOL_SIZE
- sizeof(list->count)) / sizeof(struct qla_image_version) = 6 entries actually fit. A larger count walks the image pointer off the end of the stack buffer, reading adjacent kernel stack memory and sending it to the device via qla2x00_write_sfp().
Reject requests whose declared count does not fit in the buffer.
The Linux kernel CVE team has assigned CVE-2026-89858 to this issue.
Affected and fixed versions
===========================
Issue introduced in 3.2 with commit 697a4bc69159c3396035b0506ffa55c4b2d0b1f4 and fixed in 5.10.270 with commit af733bbfcf667af1871a2735fba2835b0da71efb Issue introduced in 3.2 with commit 697a4bc69159c3396035b0506ffa55c4b2d0b1f4 and fixed in 5.15.221 with commit a9706d5e754e77515a92bb532bd0d73644979a1f Issue introduced in 3.2 with commit 697a4bc69159c3396035b0506ffa55c4b2d0b1f4 and fixed in 6.1.188 with commit 7e3154c97ec15460f715dbbe4097c255cce110b1 Issue introduced in 3.2 with commit 697a4bc69159c3396035b0506ffa55c4b2d0b1f4 and fixed in 6.6.157 with commit 047f1f7ee6f85bde28abfdda9fa550191ddc0532 Issue introduced in 3.2 with commit 697a4bc69159c3396035b0506ffa55c4b2d0b1f4 and fixed in 6.12.110 with commit f93e8039e6fd54a3c027c6184daf00b745b576a0 Issue introduced in 3.2 with commit 697a4bc69159c3396035b0506ffa55c4b2d0b1f4 and fixed in 6.18.51 with commit 7b22b4cb8822805cef7ba618da6f76e1474d68bd Issue introduced in 3.2 with commit 697a4bc69159c3396035b0506ffa55c4b2d0b1f4 and fixed in 7.2.5 with commit f2d4f025b67fcbfb2bbbadd3b5a6a43c4b436514 Issue introduced in 3.2 with commit 697a4bc69159c3396035b0506ffa55c4b2d0b1f4 and fixed in 7.3-rc1 with commit de62cf265dbe309f34f144a6cdbca9240317727e
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-89858
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/qla2xxx/qla_bsg.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/af733bbfcf667af1871a2735fba2835b0da71efb https://git.kernel.org/stable/c/a9706d5e754e77515a92bb532bd0d73644979a1f https://git.kernel.org/stable/c/7e3154c97ec15460f715dbbe4097c255cce110b1 https://git.kernel.org/stable/c/047f1f7ee6f85bde28abfdda9fa550191ddc0532 https://git.kernel.org/stable/c/f93e8039e6fd54a3c027c6184daf00b745b576a0 https://git.kernel.org/stable/c/7b22b4cb8822805cef7ba618da6f76e1474d68bd https://git.kernel.org/stable/c/f2d4f025b67fcbfb2bbbadd3b5a6a43c4b436514 https://git.kernel.org/stable/c/de62cf265dbe309f34f144a6cdbca9240317727e