]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
HID: core: do not bypass hid_hw_raw_request
authorBenjamin Tissoires <bentiss@kernel.org>
Thu, 10 Jul 2025 14:01:35 +0000 (16:01 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 24 Jul 2025 06:51:48 +0000 (08:51 +0200)
commita62a895edb2bfebffa865b5129a66e3b4287f34f
tree7dcb6236af4fbdc7e25d21512904756a702967cb
parenta95807db965d7ef9ce6c50070ab3dfb69eaabd13
HID: core: do not bypass hid_hw_raw_request

commit c2ca42f190b6714d6c481dfd3d9b62ea091c946b upstream.

hid_hw_raw_request() is actually useful to ensure the provided buffer
and length are valid. Directly calling in the low level transport driver
function bypassed those checks and allowed invalid paramto be used.

Reported-by: Alan Stern <stern@rowland.harvard.edu>
Closes: https://lore.kernel.org/linux-input/c75433e0-9b47-4072-bbe8-b1d14ea97b13@rowland.harvard.edu/
Cc: stable@vger.kernel.org
Link: https://patch.msgid.link/20250710-report-size-null-v2-3-ccf922b7c4e5@kernel.org
Signed-off-by: Benjamin Tissoires <bentiss@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/hid/hid-core.c