[PATCH net v5 0/3] net/smc: fix out-of-bounds and use-after-free in SMC-Rv2 LLC processing
Yehyeong Lee <[email protected]> Sat, 1 Aug 2026 18:42:05 +0900
| Newsgroups | org.kernel.vger.linux-hardening,org.kernel.vger.linux-kernel,org.kernel.vger.linux-rdma,org.kernel.vger.linux-s390,org.kernel.vger.netdev |
|---|---|
| Message-ID | <[email protected]> |
Split of the single v3 patch, in the order Jakub asked for:
1/3 frees the LLC queue entry in smc_llc_srv_add_link() only after the
last use of the pointer into it.
2/3 bounds the peer-declared rkey counts in smc_llc_save_add_link_rkeys()
and smc_llc_rmt_delete_rkey() by the buffer they read from.
3/3 copies an oversized SMC-Rv2 LLC message into the queue entry and
declares the rkeys that fit inline, so both consumers stop
reconstructing the layout themselves.
1/3 and 2/3 are tagged for stable. 3/3 is not: it does not fix a crash on
its own, and it changes a structure layout and a static function signature.
v5 touches 2/3 only, and only its comment and changelog: they gave
the wrong reason for skipping the extension. No functional change.
---
v4: https://lore.kernel.org/all/[email protected]/
v3: https://lore.kernel.org/all/[email protected]/
Yehyeong Lee (3):
net/smc: fix use-after-free of the LLC qentry in
smc_llc_srv_add_link()
net/smc: bound the peer rkey counts in SMC-Rv2 LLC messages
net/smc: carry oversized SMC-Rv2 LLC messages in the queue entry
net/smc/smc_llc.c | 101 ++++++++++++++++++++++++++++++++++------------
1 file changed, 76 insertions(+), 25 deletions(-)
--
2.43.0