RDMA/srpt: fix integer overflow in immediate data length check
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 5dabcd0456d7ee17c2c7a17d7c2305444d2b9639 · < 65572fbd86033ae2370125593d59b8be34253aaf| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
RDMA/srpt: fix integer overflow in immediate data length check
imm_buf->len is a user-controlled uint32_t received from the network. Adding it to imm_data_offset without overflow checking allows a malicious initiator to send len=0xFFFFFFFF, causing req_size to wrap around to a small value, bypassing the bounds check, and subsequently passing a ~4GB length to sg_init_one().
Use check_add_overflow() to detect wrapping before the comparison.
From the CVE record · Linux
The Linux kernel's RDMA/srpt component does not check for overflow when adding a network-supplied immediate data length to an offset. A malicious initiator can send a length that wraps the request size, bypasses a bounds check, and passes a roughly 4 GB length to sg_init_one(). The input does not specify authentication or user-interaction requirements.
Engineers running Linux kernels with RDMA/srpt should check their deployments; affected versions are not specified.