{"id":"CVE-2026-31401","title":"In the Linux kernel, the following vulnerability has been resolved:\n\nHID: bpf: prevent buffer overflow in hid_hw_request\n\nright now the returned value is considered to be always valid","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nHID: bpf: prevent buffer overflow in hid_hw_request\n\nright now the returned value is considered to be always valid. However,\nwhen playing with HID-BPF, the return value…","severity":"high","cvss":7.8,"cvssVector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","cwe":["CWE-787"],"vendor":"linux","product":"linux_kernel","affected":["linux_kernel >= 6.11, < 6.12.78","linux_kernel >= 6.13, < 6.18.20","linux_kernel >= 6.19, < 6.19.10","linux_kernel = 7.0"],"patched":["linux_kernel 6.19.10"],"published":"2026-04-03","updated":"2026-07-24","source":"NVD","sourceUrl":"https://nvd.nist.gov/vuln/detail/CVE-2026-31401","references":[{"url":"https://git.kernel.org/stable/c/2b658c1c442ec1cd9eec5ead98d68662c40fe645","label":"416baaa9-dc9f-4396-8d5f-8c081fb06d67"},{"url":"https://git.kernel.org/stable/c/73c5b5aea1c443239c8cb4191b4af7a4bd6fd7b1","label":"416baaa9-dc9f-4396-8d5f-8c081fb06d67"},{"url":"https://git.kernel.org/stable/c/d6efaa50af62fb0790dd1fd4e7e5506b46312510","label":"416baaa9-dc9f-4396-8d5f-8c081fb06d67"},{"url":"https://git.kernel.org/stable/c/eb57dae20fdf6f3069cdc07821fa3bb46de381d7","label":"416baaa9-dc9f-4396-8d5f-8c081fb06d67"}],"tags":["nvd"],"epss":0.00135,"epssPercentile":0.03345,"ingestedAt":"2026-07-25T22:05:04.273Z","slug":"CVE-2026-31401","body":"## Overview\n\nIn the Linux kernel, the following vulnerability has been resolved:\n\nHID: bpf: prevent buffer overflow in hid_hw_request\n\nright now the returned value is considered to be always valid. However,\nwhen playing with HID-BPF, the return value can be arbitrary big,\nbecause it's the return value of dispatch_hid_bpf_raw_requests(), which\ncalls the struct_ops and we have no guarantees that the value makes\nsense.\n\n## Affected\n\n- `linux_kernel >= 6.11, < 6.12.78`\n- `linux_kernel >= 6.13, < 6.18.20`\n- `linux_kernel >= 6.19, < 6.19.10`\n- `linux_kernel = 7.0`\n\n## Remediation\n\nUpgrade past the affected range:\n\n- `linux_kernel 6.19.10`","depth":"twilight","depthScore":43,"depthScoreParts":{"impact":42.9,"likelihood":0,"exploitation":0,"ransomware":0},"changes":[]}