CVE-2026-97413: RDMA/rtrs-srv: Fix integer underflow in process_read and process_write
In the Linux kernel, the following vulnerability has been resolved:
RDMA/rtrs-srv: Fix integer underflow in processread and processwrite
usrlen is read from a network-supplied message field (le16tocpu) and used to compute datalen = off - usrlen without validating that usrlen <= off. A malicious RDMA client can send usrlen > off causing an integer underflow, resulting in datalen wrapping to a huge sizet value which is then passed to the rdmaev callback as a memory length, leading to out-of-bounds memory access.
Fix by reading and validating usrlen <= off before rtrssrvgetopsids() in both processread() and processwrite(), ensuring the early return path acquires no reference and has no resource leak.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Compensating control
In RDMA/rtrs-srv, read and validate the network-supplied usr_len so that usr_len <= off before rtrs_srv_get_ops_ids(), and enforce this validation in both process_read() and process_write() before computing data_len = off - usr_len.
Event History
Frequently Asked Questions
What access does an attacker need to trigger the issue?
An attacker needs to act as a malicious RDMA client and send a crafted network message with a usr_len value greater than off.
What is the impact of a successful exploit?
The unchecked subtraction can underflow and wrap data_len to a very large size_t value. That value is passed as a memory length to the rdma_ev callback, which can lead to out-of-bounds memory access.
Which code paths are affected?
The issue occurs in both process_read() and process_write() in the RDMA RTRS server code.
What validation is required to prevent exploitation?
usr_len must be read and validated as less than or equal to off before rtrs_srv_get_ops_ids() is called. Invalid requests should return early before acquiring a reference.