CVE-2026-31401

HID: bpf: prevent buffer overflow in hid_hw_request

State
Published
Severity
7.8 High
Published
Apr 3, 2026
Updated
Oct 19, 2026
Reserved
Mar 9, 2026

Read the record on cve.org

Description

In the Linux kernel, the following vulnerability has been resolved:

HID: bpf: prevent buffer overflow in hid_hw_request

right now the returned value is considered to be always valid. However, when playing with HID-BPF, the return value can be arbitrary big, because it's the return value of dispatch_hid_bpf_raw_requests(), which calls the struct_ops and we have no guarantees that the value makes sense.

Scores

CVSSScoreVectorSource
3.17.8 HighCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:HLinux

Weaknesses

  • CWE-120 Buffer Copy without Checking Size of Input ('Classic Buffer Overflow')

Affected Products

ProductVersions
LinuxLinux
  • 8bd0488b5ea58655ad6fdcbe0408ef49b16882b1 to before d6efaa50af62fb0790dd1fd4e7e5506b46312510Affected
  • 8bd0488b5ea58655ad6fdcbe0408ef49b16882b1 to before 73c5b5aea1c443239c8cb4191b4af7a4bd6fd7b1Affected
  • 8bd0488b5ea58655ad6fdcbe0408ef49b16882b1 to before eb57dae20fdf6f3069cdc07821fa3bb46de381d7Affected
  • 8bd0488b5ea58655ad6fdcbe0408ef49b16882b1 to before 2b658c1c442ec1cd9eec5ead98d68662c40fe645Affected
LinuxLinux
  • 6.11Affected
  • before 6.11Not affected
  • 6.12.78 through 6.12.*Not affected
  • 6.18.20 through 6.18.*Not affected
  • 6.19.10 through 6.19.*Not affected
  • 7.0 and laterNot affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.