# CVE-2024-42285: RDMA/iwcm: Fix a use-after-free related to destroying CM IDs

- Severity: Critical 9.8 (CVSS:3.1, scored by Linux) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 1.08%, higher than 65% of CVEs (2026-11-30)
- Published: 2024-08-17T09:08:51.302Z
- Modified: 2026-08-05T11:36:21.283Z
- Weaknesses: CWE-416
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: Linux

## Description

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.

(As written by CVE List.)

## Affected

- Linux Linux: from 59c68ac31e15ad09d2cb04734e3c8c544a95f8d4 before d91d253c87fd1efece521ff2612078a35af673c6; from 59c68ac31e15ad09d2cb04734e3c8c544a95f8d4 before 7f25f296fc9bd0435be14e89bf657cd615a23574; from 59c68ac31e15ad09d2cb04734e3c8c544a95f8d4 before 94ee7ff99b87435ec63211f632918dc7f44dac79; from 59c68ac31e15ad09d2cb04734e3c8c544a95f8d4 before 557d035fe88d78dd51664f4dc0e1896c04c97cf6; from 59c68ac31e15ad09d2cb04734e3c8c544a95f8d4 before dc8074b8901caabb97c2d353abd6b4e7fa5a59a5; from 59c68ac31e15ad09d2cb04734e3c8c544a95f8d4 before ff5bbbdee08287d75d72e65b72a2b76d9637892a; from 59c68ac31e15ad09d2cb04734e3c8c544a95f8d4 before ee39384ee787e86e9db4efb843818ef0ea9cb8ae; from 59c68ac31e15ad09d2cb04734e3c8c544a95f8d4 before aee2424246f9f1dadc33faa78990c1e2eb7826e4; 4.8 (not affected: before 4.8; from 4.19.320 up to 4.19.*; from 5.4.282 up to 5.4.*; from 5.10.224 up to 5.10.*; from 5.15.165 up to 5.15.*; from 6.1.103 up to 6.1.*; from 6.6.44 up to 6.6.*; from 6.10.3 up to 6.10.*; from 6.11 up to *)
- linux linux_kernel: from 4.8 before 4.19.320; from 4.20 before 5.4.282; from 5.5 before 5.10.224; from 5.11 before 5.15.165; from 5.16 before 6.1.103; from 6.2 before 6.6.44; from 6.7 before 6.10.3

## Every score

- Linux: CVSS:3.1 9.8 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`

## References

- <https://git.kernel.org/stable/c/d91d253c87fd1efece521ff2612078a35af673c6> (patch)
- <https://git.kernel.org/stable/c/7f25f296fc9bd0435be14e89bf657cd615a23574> (patch)
- <https://git.kernel.org/stable/c/94ee7ff99b87435ec63211f632918dc7f44dac79> (patch)
- <https://git.kernel.org/stable/c/557d035fe88d78dd51664f4dc0e1896c04c97cf6> (patch)
- <https://git.kernel.org/stable/c/dc8074b8901caabb97c2d353abd6b4e7fa5a59a5> (patch)
- <https://git.kernel.org/stable/c/ff5bbbdee08287d75d72e65b72a2b76d9637892a> (patch)
- <https://git.kernel.org/stable/c/ee39384ee787e86e9db4efb843818ef0ea9cb8ae> (patch)
- <https://git.kernel.org/stable/c/aee2424246f9f1dadc33faa78990c1e2eb7826e4> (patch)
- <https://lists.debian.org/debian-lts-announce/2025/01/msg00001.html>
- <https://lists.debian.org/debian-lts-announce/2024/10/msg00003.html>

## Sources

- CVE List: [CVE-2024-42285](https://www.cve.org/CVERecord?id=CVE-2024-42285), CVE Terms of Use, modified 2026-08-05
- NVD: [CVE-2024-42285](https://nvd.nist.gov/vuln/detail/CVE-2024-42285), Public domain, modified 2026-08-04

---

Page: https://cve.day/CVE-2024-42285 · Whole record: https://cve.day/CVE-2024-42285.json · Rebuilt by cve.day 2026-11-25T22:58:44.464Z
