CVE-2026-139584
publishedIB/mad: fix UAF and double-free in RMPP receive reassembly
Package status and fixes
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| Linux | — | Linuxfa619a77046bef30478697aba0553991033afb8e to < e936a56c1ab8ba5d07938812b934b8b1d8b56dc7 · fa619a77046bef30478697aba0553991033afb8e to < d8ef8b4626d9df682bdb27be8c039f9532f07740 · fa619a77046bef30478697aba0553991033afb8e to < bebbe1555677dbfa3542d2d2caa58a9adf4ec859 · fa619a77046bef30478697aba0553991033afb8e to < ae817ef1690cadb9bb176a814f6d1d386d0a544e · fa619a77046bef30478697aba0553991033afb8e to < 2eab6afb62da0b29b731ee76f07658bda0b1dd19 · fa619a77046bef30478697aba0553991033afb8e to < 1391b9d5db622cc883e945cc0b66666f2995bfca · fa619a77046bef30478697aba0553991033afb8e to < 9edaa226ea03da865204e67f745ee974806136e3 · fa619a77046bef30478697aba0553991033afb8e to < 90e9b6357bec75f627cde1a85b5887215c80aad8 · Other versions: unaffected | Affected | Not stated | Linux |
| Linux | — | Linux2.6.13 (affected) · 0 to < 2.6.13 (unaffected · semver) · 5.10.275 through 5.10.* (unaffected · semver) · 5.15.226 through 5.15.* (unaffected · semver) · 6.1.193 through 6.1.* (unaffected · semver) · 6.6.163 through 6.6.* (unaffected · semver) · 6.12.119 through 6.12.* (unaffected · semver) · 6.18.65 through 6.18.* (unaffected · semver) · 7.3.6 through 7.3.* (unaffected · semver) · 7.4-rc1 and later (unaffected · original_commit_for_fix) · Other versions: affected | Version-specific | Not stated | Linux |
| Amazon Linux | AL2 | Release evaluation | Pending Fix | Not stated | Amazon Linux assessment |
| Amazon Linux | AL2023 | Release evaluation | Pending Fix | Not stated | Amazon Linux assessment |
Description
In the Linux kernel, the following vulnerability has been resolved: IB/mad: fix UAF and double-free in RMPP receive reassembly mad_rmpp_recv.state is protected by two locks that do not exclude each other: recv_timeout_handler() (port workqueue) uses agent->lock, continue_rmpp() (CQ softirq) uses rmpp_recv->lock. Nothing serializes the check-then-set sequence on the state word: T1 (CQ softirq) T2 (port workqueue) continue_rmpp() lock(rmpp_recv->lock) state == ACTIVE [passes] recv_timeout_handler() lock(agent->lock) state = TIMEOUT list_del(&rmpp_recv->list) unlock(agent->lock) destroy_rmpp_recv() wait_for_completion() [blocks on T1's ref] state = COMPLETE unlock(rmpp_recv->lock) complete_rmpp() queue cleanup_work (+10s) deref() [unblocks] kfree(rmpp_recv) ib_free_recv_mad(done_wc) +10s: recv_cleanup_handler() runs lock/list_del/destroy on the freed rmpp_recv -> UAF write and double free; nothing can cancel that cleanup_work anymore, the entry is already off agent->rmpp_list. done_wc is also returned to ib_mad_complete_recv() and freed again -> UAF read and double free. Reaching this requires sending MADs to a kernel RMPP agent from the InfiniBand/RoCE fabric: the per-port sa_query agent accepts subnet manager responses whose SLID/GID/TID are not authenticated on the fabric, and legacy user_mad agents registered without IB_USER_MAD_USER_RMPP start reassembly on any incoming RMPP DATA MAD with an attacker-chosen TID, no in-flight send required. The attacker controls segment timing and can run many transactions in parallel (agent->rmpp_list has no cap), so landing the microseconds-wide receive critical section on the 40-second timeout boundary is a matter of patience, not luck. Unify state transitions under rmpp_recv->lock in recv_timeout_handler(), keeping list manipulation under agent->lock (which preserves the agent->lock -> rmpp_recv->lock ordering used by continue_rmpp()). State check/set in both paths is then serialized, so the loser of the race always observes the final state and bails out. recv_cleanup_handler() needs no change: with transitions serialized, a cleanup_work can only be pending after COMPLETE, in which case the timeout handler exits early. The race is as old as the RMPP implementation itself.
Related advisories
Vendor advisories explicitly linked to this CVE.
No linked advisories were found for this CVE.
Assessment
CVSS risk assessment and additional context for this vulnerability.
No normalized assessments.
Publisher product statements
Version ranges and default statuses as reported by each provider.
| Vendor | Product | Version status | Source |
|---|---|---|---|
| Linux | Linux | fa619a77046bef30478697aba0553991033afb8e to < e936a56c1ab8ba5d07938812b934b8b1d8b56dc7 (affected · git)fa619a77046bef30478697aba0553991033afb8e to < d8ef8b4626d9df682bdb27be8c039f9532f07740 (affected · git)fa619a77046bef30478697aba0553991033afb8e to < bebbe1555677dbfa3542d2d2caa58a9adf4ec859 (affected · git)fa619a77046bef30478697aba0553991033afb8e to < ae817ef1690cadb9bb176a814f6d1d386d0a544e (affected · git)fa619a77046bef30478697aba0553991033afb8e to < 2eab6afb62da0b29b731ee76f07658bda0b1dd19 (affected · git)fa619a77046bef30478697aba0553991033afb8e to < 1391b9d5db622cc883e945cc0b66666f2995bfca (affected · git)fa619a77046bef30478697aba0553991033afb8e to < 9edaa226ea03da865204e67f745ee974806136e3 (affected · git)fa619a77046bef30478697aba0553991033afb8e to < 90e9b6357bec75f627cde1a85b5887215c80aad8 (affected · git)Default: unaffected | Linux · cna |
| Linux | Linux | 2.6.13 (affected)0 to < 2.6.13 (unaffected · semver)5.10.275 through 5.10.* (unaffected · semver)5.15.226 through 5.15.* (unaffected · semver)6.1.193 through 6.1.* (unaffected · semver)6.6.163 through 6.6.* (unaffected · semver)6.12.119 through 6.12.* (unaffected · semver)6.18.65 through 6.18.* (unaffected · semver)7.3.6 through 7.3.* (unaffected · semver)7.4-rc1 and later (unaffected · original_commit_for_fix)Default: affected | Linux · cna |
Weaknesses
0No weakness assertions.
References
8- https://git.kernel.org/stable/c/1391b9d5db622cc883e945cc0b66666f2995bfca
- https://git.kernel.org/stable/c/2eab6afb62da0b29b731ee76f07658bda0b1dd19
- https://git.kernel.org/stable/c/90e9b6357bec75f627cde1a85b5887215c80aad8
- https://git.kernel.org/stable/c/9edaa226ea03da865204e67f745ee974806136e3
- https://git.kernel.org/stable/c/ae817ef1690cadb9bb176a814f6d1d386d0a544e
- https://git.kernel.org/stable/c/bebbe1555677dbfa3542d2d2caa58a9adf4ec859
- https://git.kernel.org/stable/c/d8ef8b4626d9df682bdb27be8c039f9532f07740
- https://git.kernel.org/stable/c/e936a56c1ab8ba5d07938812b934b8b1d8b56dc7
Provider assertions
1Linux · cna
IB/mad: fix UAF and double-free in RMPP receive reassembly
Provenance
- Schema
- 5.2
- Searchable
- yes
- Content hash
- 45bedcf48a060fcd095f21acf465a9c81b4dde65aef0fa58c0145f82b6a5c018
- Ingested
- 30 Nov 2026, 13:42:24 UTC
- Source record
- Official CVE record