CVE-2026-139591
RDMA/mlx5: Restore mr->pi_mr after temporary stack-local assignment
Description
In the Linux kernel, the following vulnerability has been resolved: RDMA/mlx5: Restore mr->pi_mr after temporary stack-local assignment In handle_reg_mr_integrity, when mr->pi_mr is NULL (physical-address optimization path), the code points mr->pi_mr at a stack-local pa_pi_mr so set_pi_umr_wr can read it during this call. The pointer is never restored, so after the function returns mr->pi_mr dangles at a freed stack frame. A second IB_WR_REG_MR_INTEGRITY posted on the same MR without remapping reads the stale pointer and dereferences it. Save the original pi_mr (captured at function entry) and restore it on the out path.
INFO
Published Date :
Nov. 30, 2026, 2:19 p.m.
Last Modified :
Nov. 30, 2026, 2:19 p.m.
Remotely Exploit :
No
Source :
416baaa9-dc9f-4396-8d5f-8c081fb06d67
Solution
- Save original pi_mr pointer at function entry.
- Restore pi_mr pointer on function exit.
- Apply kernel patch to fix pointer issue.
References to Advisories, Solutions, and Tools
Here, you will find a curated list of external links that provide in-depth
information, practical solutions, and valuable tools related to
CVE-2026-139591.
CWE - Common Weakness Enumeration
While CVE identifies
specific instances of vulnerabilities, CWE categorizes the common flaws or
weaknesses that can lead to vulnerabilities. CVE-2026-139591 is
associated with the following CWEs:
Common Attack Pattern Enumeration and Classification (CAPEC)
Common Attack Pattern Enumeration and Classification
(CAPEC)
stores attack patterns, which are descriptions of the common attributes and
approaches employed by adversaries to exploit the CVE-2026-139591
weaknesses.
We scan GitHub repositories to detect new proof-of-concept exploits. Following list is a collection of public exploits and proof-of-concepts, which have been published on GitHub (sorted by the most recently updated).
Results are limited to the first 15 repositories due to potential performance issues.
The following list is the news that have been mention
CVE-2026-139591 vulnerability anywhere in the article.
The following table lists the changes that have been made to the
CVE-2026-139591 vulnerability over time.
Vulnerability history details can be useful for understanding the evolution of a vulnerability, and for identifying the most recent changes that may impact the vulnerability's severity, exploitability, or other characteristics.
-
New CVE Received by 416baaa9-dc9f-4396-8d5f-8c081fb06d67
Nov. 30, 2026
Action Type Old Value New Value Added Description In the Linux kernel, the following vulnerability has been resolved: RDMA/mlx5: Restore mr->pi_mr after temporary stack-local assignment In handle_reg_mr_integrity, when mr->pi_mr is NULL (physical-address optimization path), the code points mr->pi_mr at a stack-local pa_pi_mr so set_pi_umr_wr can read it during this call. The pointer is never restored, so after the function returns mr->pi_mr dangles at a freed stack frame. A second IB_WR_REG_MR_INTEGRITY posted on the same MR without remapping reads the stale pointer and dereferences it. Save the original pi_mr (captured at function entry) and restore it on the out path. Added Affected New affected value received. <a href="https://github.com/CVEProject/cvelistV5/blob/main/cves/2026/139xxx/CVE-2026-139591.json">CVE-2026-139591</a> Added Reference https://git.kernel.org/stable/c/0f2dc4ec62d86316d01bf509788463c5c35f0160 Added Reference https://git.kernel.org/stable/c/0fabd08ceacbc1368a1e6459a438a49884145320 Added Reference https://git.kernel.org/stable/c/46f20f6e193f20892d2a5e2af7c4143d2a27562c Added Reference https://git.kernel.org/stable/c/5130c610180ad57c7a8ce35868b5b49f24de4a84 Added Reference https://git.kernel.org/stable/c/54f3563103e3bb988a6d57d655568ad0aed9576b Added Reference https://git.kernel.org/stable/c/76d6f0e04e567db3ebe28e695bbdb3cc4e007d82 Added Reference https://git.kernel.org/stable/c/91264cb942b762b6b86fc2cb10c38bfdc31c36fb Added Reference https://git.kernel.org/stable/c/9728effe43d8fc4d58e12b697d0d6127355abdd5