{"id":"CVE-2026-97496","aliases":["CVE-2026-97496"],"related":[],"kind":"vulnerability","state":"published","title":"drm/amdkfd: Fix OOB memory exposure in get_wave_state()","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\ndrm/amdkfd: Fix OOB memory exposure in get_wave_state()\n\nThe get_wave_state() function for v9 trusts cp_hqd_cntl_stack_size and\ncp_hqd_cntl_stack_offset values read directly from the MQD, which are\nwritten by GPU microcode and fully attacker-controlled on the\nCRIU-restore path (via AMDKFD_IOC_RESTORE_PROCESS with H3).\n\nthis leads to an unbounded copy_to_user() that can leak adjacent\nGTT/kernel memory. If offset > size, integer underflow produces a ~4 GiB\nread length, if size is set to 1 MiB against a 4 KiB allocation, we leak\n1 MiB of adjacent kernel memory (other queues' MQDs, ring buffers, KASLR\npointers).\n\nFix by clamping both cp_hqd_cntl_stack_size to the actual allocated\nbuffer size (q->ctl_stack_size) and cp_hqd_cntl_stack_offset to the\nclamped size before performing arithmetic and copy_to_user().\n\nThis ensures we never read beyond the allocated kernel BO regardless of\nattacker-supplied MQD field values.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\ndrm/amdkfd: Fix OOB memory exposure in get_wave_state()\n\nThe get_wave_state() function for v9 trusts cp_hqd_cntl_stack_size and\ncp_hqd_cntl_stack_offset values read directly from the MQD, which are\nwritten by GPU microcode and fully attacker-controlled on the\nCRIU-restore path (via AMDKFD_IOC_RESTORE_PROCESS with H3).\n\nthis leads to an unbounded copy_to_user() that can leak adjacent\nGTT/kernel memory. If offset > size, integer underflow produces a ~4 GiB\nread length, if size is set to 1 MiB against a 4 KiB allocation, we leak\n1 MiB of adjacent kernel memory (other queues' MQDs, ring buffers, KASLR\npointers).\n\nFix by clamping both cp_hqd_cntl_stack_size to the actual allocated\nbuffer size (q->ctl_stack_size) and cp_hqd_cntl_stack_offset to the\nclamped size before performing arithmetic and copy_to_user().\n\nThis ensures we never read beyond the allocated kernel BO regardless of\nattacker-supplied MQD field values.","source":"cvelist"}],"published":"2026-09-24T16:04:43.625Z","modified":"2026-10-03T11:17:59.480Z","severity":{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H","score":7.1,"rating":"HIGH"},"severities":[{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H","score":7.1,"rating":"HIGH"}],"cwes":[],"affected":[{"ranges":[{"type":"git","introduced":"42c6c48214b726c30918e8dc80e2168607d13ae4","fixed":"e2bef0f168be46692a6b900916ff5da3771480ed","status":"affected"},{"type":"git","introduced":"42c6c48214b726c30918e8dc80e2168607d13ae4","fixed":"d9183d974ddd5f09d029beaf359275ac20d4d5fe","status":"affected"},{"type":"git","introduced":"42c6c48214b726c30918e8dc80e2168607d13ae4","fixed":"ec646686613d8ab05b282d1463a7baa49fd6b83b","status":"affected"},{"type":"git","introduced":"42c6c48214b726c30918e8dc80e2168607d13ae4","fixed":"7ef144458f48d5589e36f1b3d83e83db2e5c5ba5","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"5.18","status":"affected"},{"type":"semver","introduced":"0","fixed":"5.18","status":"unaffected"},{"type":"semver","introduced":"6.6.158","lastAffected":"6.6.*","status":"unaffected"},{"type":"semver","introduced":"6.12.111","lastAffected":"6.12.*","status":"unaffected"},{"type":"semver","introduced":"6.18.53","lastAffected":"6.18.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"7.2","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"}],"references":[{"url":"https://git.kernel.org/stable/c/e2bef0f168be46692a6b900916ff5da3771480ed","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/d9183d974ddd5f09d029beaf359275ac20d4d5fe","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/ec646686613d8ab05b282d1463a7baa49fd6b83b","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/7ef144458f48d5589e36f1b3d83e83db2e5c5ba5","tags":[],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-97496","url":"https://www.cve.org/CVERecord?id=CVE-2026-97496","licence":"CVE Terms of Use","modified":"2026-10-03T10:58:59.453Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-97496","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-97496","licence":"Public domain","modified":"2026-10-03T11:17:59.480Z"}],"updatedAt":"2026-11-25T22:59:40.868Z","epss":{"score":0.00125,"percentile":0.02394,"date":"2026-12-02T12:00:21.000Z"}}