RDMA/cma: Fix hang when cma_netevent_callback fails to queue_work
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
b172a4a0de254f1fcce7591833a9a63547c2f447| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
RDMA/cma: Fix hang when cma_netevent_callback fails to queue_work
The cited commit fixed a crash when cma_netevent_callback was called for a cma_id while work on that id from a previous call had not yet started. The work item was re-initialized in the second call, which corrupted the work item currently in the work queue.
However, it left a problem when queue_work fails (because the item is still pending in the work queue from a previous call). In this case, cma_id_put (which is called in the work handler) is therefore not called. This results in a userspace process hang (zombie process).
Fix this by calling cma_id_put() if queue_work fails.
From the CVE record · Linux
The Linux kernel's RDMA/cma code can leave a userspace process hung as a zombie when cma_netevent_callback fails to queue work that is still pending. The input does not specify an attacker, access requirements, or whether user interaction is needed.
Engineers running Linux kernels with RDMA/cma should check their versions; affected versions are not specified.