]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
USB: serial: io_ti: fix information leak in completion handler
authorJohan Hovold <johan@kernel.org>
Mon, 6 Mar 2017 16:36:40 +0000 (17:36 +0100)
committerJiri Slaby <jslaby@suse.cz>
Tue, 28 Mar 2017 13:49:17 +0000 (15:49 +0200)
commitef598b806384182a74f2aa9bc24a0284faf3940e
tree788208d9b7f4b67d665e3980c557aefee1d729b0
parent718f8e2cce2371893db7e4c82359b0d00804e3c6
USB: serial: io_ti: fix information leak in completion handler

commit 654b404f2a222f918af9b0cd18ad469d0c941a8e upstream.

Add missing sanity check to the bulk-in completion handler to avoid an
integer underflow that can be triggered by a malicious device.

This avoids leaking 128 kB of memory content from after the URB transfer
buffer to user space.

Fixes: 8c209e6782ca ("USB: make actual_length in struct urb field u32")
Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
drivers/usb/serial/io_ti.c