# CVE-2026-98366: RDMA/rxe: validate access flags before swapping the MR's PD

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.8
- **CVSS:** 7.8 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: High; Integrity impact: High; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.17% (percentile 4, 2026-11-26)
- **Published:** 2026-10-06T08:46:51.638Z
- **Modified:** 2026-10-19T10:18:39.543Z

## Who should check

- Anyone running Linux \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< 08f12745cb72981aa2cabe214af0c7a42a856f0a; \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< 7230cc456d4bb2221c20c5f1d22b38b8576aa16f; \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< fe602c91a52e161ace4afd5bdb8f33270c554c6f; \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< 4dd7a53f1c5b44693c26dac4b9b5bd5bb9d604c8; \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< ae36a5b609ae79f4de966328b78d2584be9719a4
- Anyone running Linux 6.5

## Description

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

RDMA/rxe: validate access flags before swapping the MR's PD

rxe\_rereg\_user\_mr() reassigns mr-\>ibmr.pd first and only then
validates the IB\_MR\_REREG\_ACCESS argument:

	if (flags & IB\_MR\_REREG\_PD) {
		rxe\_put(old\_pd);
		rxe\_get(pd);
		mr-\>ibmr.pd = ibpd;
	}

	if (flags & IB\_MR\_REREG\_ACCESS) {
		if (access & ~RXE\_ACCESS\_SUPPORTED\_MR)
			return ERR\_PTR(-EOPNOTSUPP);
		mr-\>access = access;
	}

Both flags pass the entry check because RXE\_MR\_REREG\_SUPPORTED is
IB\_MR\_REREG\_PD \| IB\_MR\_REREG\_ACCESS, so a caller can reach the access
check with mr-\>ibmr.pd already reassigned.

mr-\>ibmr.pd is owned by the core, which adjusts pd-\>usecnt only on the
success path: ib\_uverbs\_rereg\_mr() jumps to put\_new\_uobj on a driver error
without undoing the reassignment, so mr-\>pd == new\_pd while the usecnts
still charge the MR to orig\_pd. ib\_dereg\_mr\_user() then decrements
new\_pd, whose count can reach zero while a memory window still references
it; uverbs\_free\_pd() frees the PD on that count alone and rxe\_mw\_cleanup()
writes to freed memory:

  BUG: KASAN: slab-use-after-free in \_\_rxe\_put+0x31/0xa0
  Write of size 4 at addr ffff8881301dd690 by task rxe\_poc/591
   \_\_rxe\_put+0x31/0xa0
   rxe\_mw\_cleanup+0x42/0x200
   \_\_rxe\_cleanup+0x115/0x370
   rxe\_dealloc\_mw+0x4c/0x80
  Allocated by task 591:
   ib\_uverbs\_alloc\_pd+0x258/0x540
  Freed by task 591:
   ib\_dealloc\_pd\_user+0x174/0x210
   uverbs\_free\_pd+0x8d/0xc0
   ib\_uverbs\_dealloc\_pd+0x18e/0x1d0

Validate the access flags before mutating any state so the callback either
applies every requested change or none.

## Affected and fixed versions

- Linux: \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< 08f12745cb72981aa2cabe214af0c7a42a856f0a; \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< 7230cc456d4bb2221c20c5f1d22b38b8576aa16f; \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< fe602c91a52e161ace4afd5bdb8f33270c554c6f; \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< 4dd7a53f1c5b44693c26dac4b9b5bd5bb9d604c8; \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< ae36a5b609ae79f4de966328b78d2584be9719a4 (cvelist)
- Linux: 6.5 (cvelist)

## Mitigation

- No fix listed yet: follow the vendor advisory.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2026-98366. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-98366.md
Affected: Linux >= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, < 08f12745cb72981aa2cabe214af0c7a42a856f0a; >= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, < 7230cc456d4bb2221c20c5f1d22b38b8576aa16f; >= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, < fe602c91a52e161ace4afd5bdb8f33270c554c6f; >= 544c7f62cf32db2bd358f1e…
Fixed in: Linux 08f12745cb72981aa2cabe214af0c7a42a856f0a, Linux 7230cc456d4bb2221c20c5f1d22b38b8576aa16f, Linux 4dd7a53f1c5b44693c26dac4b9b5bd5bb9d604c8

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2026-98366 being exploited?

There is no confirmed exploitation: CVE-2026-98366 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.17% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2026-98366?

High: CVSS 7.8 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2026-98366?

Linux \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< 08f12745cb72981aa2cabe214af0c7a42a856f0a; \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< 7230cc456d4bb2221c20c5f1d22b38b8576aa16f; \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< fe602c91a52e161ace4afd5bdb8f33270c554c6f; \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< 4dd7a53f1c5b44693c26dac4b9b5bd5bb9d604c8; \>= 544c7f62cf32db2bd358f1e8a40a98bf98fa2a5c, \< ae36a5b609ae79f4de966328b78d2584be9719a4; Linux 6.5.

### Is there a fix for CVE-2026-98366?

Yes. Fixed in Linux 08f12745cb72981aa2cabe214af0c7a42a856f0a, Linux 7230cc456d4bb2221c20c5f1d22b38b8576aa16f, Linux 4dd7a53f1c5b44693c26dac4b9b5bd5bb9d604c8. No fix listed yet: follow the vendor advisory.

### How do I check if I'm affected by CVE-2026-98366?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- other: <https://git.kernel.org/stable/c/08f12745cb72981aa2cabe214af0c7a42a856f0a>
- other: <https://git.kernel.org/stable/c/7230cc456d4bb2221c20c5f1d22b38b8576aa16f>
- other: <https://git.kernel.org/stable/c/fe602c91a52e161ace4afd5bdb8f33270c554c6f>
- other: <https://git.kernel.org/stable/c/4dd7a53f1c5b44693c26dac4b9b5bd5bb9d604c8>
- other: <https://git.kernel.org/stable/c/ae36a5b609ae79f4de966328b78d2584be9719a4>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2026-98366>

HTML: <https://flawdb.com/CVE-2026-98366> · JSON: <https://flawdb.com/api/v1/entries/CVE-2026-98366>
