CVE-2026-74346: RDMA/irdma: Fix OOB read during CQ MR registration

Greg Kroah-Hartman <[email protected]>
Newsgroups org.kernel.vger.linux-cve-announce
Message-ID <2026081558-CVE-2026-74346-872c@gregkh>
From: Greg Kroah-Hartman <[email protected]>

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

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

RDMA/irdma: Fix OOB read during CQ MR registration

Sashiko pointed out an unrelated bug during a previous patch:
https://sashiko.dev/#/patchset/20260512183852.614045-1-jmoroni%40google.com

This change fixes the bug by eliminating the cqmr->split field which
was not being set properly and instead just checks the CQ resize
feature flag directly.

The cqmr->split field essentially tracks whether IRDMA_FEATURE_CQ_RESIZE
is set, but it was not being set until CQ creation time, which is _after_
CQ memory registration (the only other place where it is referenced).

As a result, it would always be false during MR registration and would
therefore cause irdma_handle_q_mem to populate cqmr->shadow even for GEN_2
HW and beyond:

    cqmr->shadow = (dma_addr_t)arr[req->cq_pages];

The issue is that for GEN_2 and beyond, req->cq_pages may be exactly equal
to iwmr->page_cnt and therefore equal to the size of arr, which would cause
an OOB read by one.

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


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

	Issue introduced in 5.14 with commit b48c24c2d710cf34810c555dcef883a3d35a9c08 and fixed in 5.15.212 with commit a80b3b13786e9ab1c52b31a1f16c7d6708fa9220
	Issue introduced in 5.14 with commit b48c24c2d710cf34810c555dcef883a3d35a9c08 and fixed in 6.1.178 with commit 3159c6fac43dc24b34d31971884d98a7a1bf4c4b
	Issue introduced in 5.14 with commit b48c24c2d710cf34810c555dcef883a3d35a9c08 and fixed in 6.6.145 with commit ad360a31092a870633ec255b96f50181628b4de0
	Issue introduced in 5.14 with commit b48c24c2d710cf34810c555dcef883a3d35a9c08 and fixed in 6.12.97 with commit d566002de555b18cc395012c5c1cb8682fc6d2a9
	Issue introduced in 5.14 with commit b48c24c2d710cf34810c555dcef883a3d35a9c08 and fixed in 6.18.40 with commit 54cab78df0375196aaec4e3109191653d21751df
	Issue introduced in 5.14 with commit b48c24c2d710cf34810c555dcef883a3d35a9c08 and fixed in 7.1.5 with commit d5aa82da8f65562da996d184686db9d0ea718b91
	Issue introduced in 5.14 with commit b48c24c2d710cf34810c555dcef883a3d35a9c08 and fixed in 7.2-rc1 with commit 4385ddd654d90245eeb83b3cb539670ab5c85ba4

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-74346
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/infiniband/hw/irdma/verbs.c
	drivers/infiniband/hw/irdma/verbs.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/a80b3b13786e9ab1c52b31a1f16c7d6708fa9220
	https://git.kernel.org/stable/c/3159c6fac43dc24b34d31971884d98a7a1bf4c4b
	https://git.kernel.org/stable/c/ad360a31092a870633ec255b96f50181628b4de0
	https://git.kernel.org/stable/c/d566002de555b18cc395012c5c1cb8682fc6d2a9
	https://git.kernel.org/stable/c/54cab78df0375196aaec4e3109191653d21751df
	https://git.kernel.org/stable/c/d5aa82da8f65562da996d184686db9d0ea718b91
	https://git.kernel.org/stable/c/4385ddd654d90245eeb83b3cb539670ab5c85ba4
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.