{"id":"CVE-2024-46818","state":"PUBLISHED","title":"drm/amd/display: Check gpio_id before used as array index","description":"In the Linux kernel, the following vulnerability has been resolved:\n\ndrm/amd/display: Check gpio_id before used as array index\n\n[WHY & HOW]\nGPIO_ID_UNKNOWN (-1) is not a valid value for array index and therefore\nshould be checked in advance.\n\nThis fixes 5 OVERRUN issues reported by Coverity.","publishedAt":"2024-09-27T12:35:59.187Z","updatedAt":"2026-08-05T11:38:49.209Z","severity":{"score":7.8,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","source":"Linux"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"8520fdc8ecc38f240a8e9e7af89cca6739c3e790","versionType":"git"},{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"40c2e8bc117cab8bca8814735f28a8b121654a84","versionType":"git"},{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"0184cca30cad74d88f5c875d4e26999e26325700","versionType":"git"},{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"276e3fd93e3beb5894eb1cc8480f9f417d51524d","versionType":"git"},{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"08e7755f754e3d2cef7d3a7da538d33526bd6f7c","versionType":"git"},{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"3d4198ab612ad48f73383ad3bb5663e6f0cdf406","versionType":"git"},{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"2a5626eeb3b5eec7a36886f9556113dd93ec8ed6","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/gpu/drm/amd/display/dc/gpio/gpio_service.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"4.15","status":"affected"},{"version":"0","status":"unaffected","lessThan":"4.15","versionType":"semver"},{"version":"5.4.284","status":"unaffected","lessThanOrEqual":"5.4.*","versionType":"semver"},{"version":"5.10.226","status":"unaffected","lessThanOrEqual":"5.10.*","versionType":"semver"},{"version":"5.15.167","status":"unaffected","lessThanOrEqual":"5.15.*","versionType":"semver"},{"version":"6.1.109","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.6.50","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.10.9","status":"unaffected","lessThanOrEqual":"6.10.*","versionType":"semver"},{"version":"6.11","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/gpu/drm/amd/display/dc/gpio/gpio_service.c"]}],"references":["https://git.kernel.org/stable/c/8520fdc8ecc38f240a8e9e7af89cca6739c3e790","https://git.kernel.org/stable/c/40c2e8bc117cab8bca8814735f28a8b121654a84","https://git.kernel.org/stable/c/0184cca30cad74d88f5c875d4e26999e26325700","https://git.kernel.org/stable/c/276e3fd93e3beb5894eb1cc8480f9f417d51524d","https://git.kernel.org/stable/c/08e7755f754e3d2cef7d3a7da538d33526bd6f7c","https://git.kernel.org/stable/c/3d4198ab612ad48f73383ad3bb5663e6f0cdf406","https://git.kernel.org/stable/c/2a5626eeb3b5eec7a36886f9556113dd93ec8ed6","https://lists.debian.org/debian-lts-announce/2025/01/msg00001.html","https://lists.debian.org/debian-lts-announce/2024/10/msg00003.html"],"weaknesses":[],"ingestedAt":"2026-10-29T20:07:47.831Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2024/46xxx/CVE-2024-46818.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2024-46818","state":"PUBLISHED","datePublished":"2024-09-27T12:35:59.187Z","dateUpdated":"2026-08-05T11:38:49.209Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2024-09-11T15:12:18.284Z"},"containers":{"cna":{"title":"drm/amd/display: Check gpio_id before used as array index","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\ndrm/amd/display: Check gpio_id before used as array index\n\n[WHY & HOW]\nGPIO_ID_UNKNOWN (-1) is not a valid value for array index and therefore\nshould be checked in advance.\n\nThis fixes 5 OVERRUN issues reported by Coverity."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"8520fdc8ecc38f240a8e9e7af89cca6739c3e790","versionType":"git"},{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"40c2e8bc117cab8bca8814735f28a8b121654a84","versionType":"git"},{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"0184cca30cad74d88f5c875d4e26999e26325700","versionType":"git"},{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"276e3fd93e3beb5894eb1cc8480f9f417d51524d","versionType":"git"},{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"08e7755f754e3d2cef7d3a7da538d33526bd6f7c","versionType":"git"},{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"3d4198ab612ad48f73383ad3bb5663e6f0cdf406","versionType":"git"},{"version":"4562236b3bc0a28aeb6ee93b2d8a849a4c4e1c7c","status":"affected","lessThan":"2a5626eeb3b5eec7a36886f9556113dd93ec8ed6","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/gpu/drm/amd/display/dc/gpio/gpio_service.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"4.15","status":"affected"},{"version":"0","status":"unaffected","lessThan":"4.15","versionType":"semver"},{"version":"5.4.284","status":"unaffected","lessThanOrEqual":"5.4.*","versionType":"semver"},{"version":"5.10.226","status":"unaffected","lessThanOrEqual":"5.10.*","versionType":"semver"},{"version":"5.15.167","status":"unaffected","lessThanOrEqual":"5.15.*","versionType":"semver"},{"version":"6.1.109","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.6.50","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.10.9","status":"unaffected","lessThanOrEqual":"6.10.*","versionType":"semver"},{"version":"6.11","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/gpu/drm/amd/display/dc/gpio/gpio_service.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/8520fdc8ecc38f240a8e9e7af89cca6739c3e790"},{"url":"https://git.kernel.org/stable/c/40c2e8bc117cab8bca8814735f28a8b121654a84"},{"url":"https://git.kernel.org/stable/c/0184cca30cad74d88f5c875d4e26999e26325700"},{"url":"https://git.kernel.org/stable/c/276e3fd93e3beb5894eb1cc8480f9f417d51524d"},{"url":"https://git.kernel.org/stable/c/08e7755f754e3d2cef7d3a7da538d33526bd6f7c"},{"url":"https://git.kernel.org/stable/c/3d4198ab612ad48f73383ad3bb5663e6f0cdf406"},{"url":"https://git.kernel.org/stable/c/2a5626eeb3b5eec7a36886f9556113dd93ec8ed6"}],"metrics":[{"cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","baseScore":7.8,"baseSeverity":"HIGH"},"scenarios":[{"lang":"en","value":"AV:L - The vulnerable GPIO service paths are reached only through the local AMD display driver — DRM atomic modeset/stereo ioctls on /dev/dri/card0 and link detect/encoder enable on hotplug. There is no network or remote-peer input anywhere on the path.\nAC:L - In the affected versions `id` is an uninitialized stack variable in `dal_gpio_service_create_generic_mux()`/`create_irq()` that `offset_to_id()` leaves unwritten on its DDC arms, so the index is residual stack data a local caller can groom via repeated ioctls before triggering the modeset. No race or unpredictable external state is required.\nPR:L - An unprivileged local user with a graphical session holds DRM master on the card node and can issue the atomic commits that drive `dc_set_generic_gpio_for_stereo()` and encoder enable/disable. No CAP_SYS_ADMIN or root is needed.\nUI:N - The attacker drives the modeset and GPIO open/close sequence entirely from their own process; no second user must open a file, plug in a display, or take any action.\nS:U - The out-of-bounds access corrupts kernel memory belonging to the same kernel security authority; there is no VM, IOMMU, or sandbox boundary crossed.\nC:H - `busyness[-1]` loads `factory.funcs` (a kernel `.rodata` pointer) and `is_pin_busy()` dereferences it at attacker-influenced offset `en`, and a groomed index yields an out-of-bounds pointer load plus read — memory corruption of this shape is leverageable for kernel memory disclosure and KASLR defeat.\nI:H - `set_pin_busy()`/`set_pin_free()` perform an out-of-bounds write (`busyness[id][en] = true/false`) through that out-of-bounds-loaded pointer, landing in the `const struct hw_factory_funcs` vtable whose entries are later invoked indirectly (`funcs->init_ddc_data`, `funcs->get_ddc_pin`), giving a path to control-flow corruption.\nA:H - Writing through the negative index hits read-only `.rodata` under CONFIG_STRICT_KERNEL_RWX, or a wild pointer with a groomed index, producing an immediate kernel oops/panic; the ASSERT_CRITICAL paths do not prevent the access."}]}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-08-05T11:38:49.209Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.15","versionEndExcluding":"5.4.284"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.15","versionEndExcluding":"5.10.226"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.15","versionEndExcluding":"5.15.167"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.15","versionEndExcluding":"6.1.109"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.15","versionEndExcluding":"6.6.50"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.15","versionEndExcluding":"6.10.9"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.15","versionEndExcluding":"6.11"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}},"adp":[{"title":"CISA ADP Vulnrichment","metrics":[{"other":{"type":"ssvc","content":{"timestamp":"2024-09-29T14:15:06.184629Z","id":"CVE-2024-46818","options":[{"Exploitation":"none"},{"Automatable":"no"},{"Technical Impact":"partial"}],"role":"CISA Coordinator","version":"2.0.3"}}}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2024-09-29T14:15:15.550Z"}},{"title":"CVE Program Container","references":[{"url":"https://lists.debian.org/debian-lts-announce/2025/01/msg00001.html"},{"url":"https://lists.debian.org/debian-lts-announce/2024/10/msg00003.html"}],"providerMetadata":{"shortName":"CVE","orgId":"af854a3a-2127-422b-91ae-364da2661108","dateUpdated":"2025-11-03T22:19:05.133Z"}}]}}}