RDMA/iwcm: Fix a use-after-free related to destroying CM IDs
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 59c68ac31e15ad09d2cb04734e3c8c544a95f8d4 · < ff5bbbdee08287d75d72e65b72a2b76d9637892a| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
RDMA/iwcm: Fix a use-after-free related to destroying CM IDs
iw_conn_req_handler() associates a new struct rdma_id_private (conn_id) with an existing struct iw_cm_id (cm_id) as follows:
conn_id->cm_id.iw = cm_id; cm_id->context = conn_id; cm_id->cm_handler = cma_iw_handler;
rdma_destroy_id() frees both the cm_id and the struct rdma_id_private. Make sure that cm_work_handler() does not trigger a use-after-free by only freeing of the struct rdma_id_private after all pending work has finished.
From the CVE record · Linux
The Linux kernel's RDMA/iwcm connection-management code has a use-after-free involving destruction of CM IDs while work is pending. The input does not specify how an attacker could trigger it, what they could achieve, or whether network access, authentication, or user interaction is required.
Engineers running Linux kernels should check for affected versions; none are specified in the input.