android_kernel_oneplus_msm8998/drivers/usb/misc
Johan Hovold 73490abe24 USB: uss720: fix NULL-deref at probe
commit f259ca3eed6e4b79ac3d5c5c9fb259fb46e86217 upstream.

Make sure to check the number of endpoints to avoid dereferencing a
NULL-pointer or accessing memory beyond the endpoint array should a
malicious device lack the expected endpoints.

Note that the endpoint access that causes the NULL-deref is currently
only used for debugging purposes during probe so the oops only happens
when dynamic debugging is enabled. This means the driver could be
rewritten to continue to accept device with only two endpoints, should
such devices exist.

Fixes: 1da177e4c3 ("Linux-2.6.12-rc2")
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-03-30 09:35:16 +02:00
..
sisusbvga USB: sisusb_con.c: move assignment out of if () block 2015-05-10 16:01:12 +02:00
adutux.c USB: adutux: NULL dereferences on disconnect 2014-11-26 19:50:15 -08:00
appledisplay.c USB: appledisplay: Deletion of a check before backlight_device_unregister() 2015-03-18 16:56:40 +01:00
chaoskey.c USB: chaoskey read offset bug 2015-10-04 11:01:13 +01:00
cypress_cy7c63.c usb: delete non-required instances of include <linux/init.h> 2014-01-08 15:01:39 -08:00
cytherm.c usb: delete non-required instances of include <linux/init.h> 2014-01-08 15:01:39 -08:00
ehset.c usb: ehci: Add support for SINGLE_STEP_SET_FEATURE test of EHSET 2013-08-12 13:13:32 -07:00
emi26.c usb: delete non-required instances of include <linux/init.h> 2014-01-08 15:01:39 -08:00
emi62.c usb: delete non-required instances of include <linux/init.h> 2014-01-08 15:01:39 -08:00
ezusb.c usb: delete non-required instances of include <linux/init.h> 2014-01-08 15:01:39 -08:00
ftdi-elan.c usb: misc: ftdi-elan: Simplify return statement 2015-08-05 12:37:21 -07:00
idmouse.c usb: delete non-required instances of include <linux/init.h> 2014-01-08 15:01:39 -08:00
iowarrior.c USB: iowarrior: fix NULL-deref in write 2017-03-18 19:09:58 +08:00
isight_firmware.c
Kconfig usb/misc: fix chaoskey build, needs HW_RANDOM 2015-04-03 19:03:15 +02:00
ldusb.c usb, HID: Remove Vernier devices from lsusb and hid_ignore_list 2015-06-01 14:44:08 +02:00
legousbtower.c usb: misc: legousbtower: Fix NULL pointer deference 2016-10-07 15:23:47 +02:00
lvstest.c Pratyush Anand has moved 2015-06-25 17:00:38 -07:00
Makefile usb: Add driver for Altus Metrum ChaosKey device (v2) 2015-03-26 10:47:11 +01:00
rio500.c usb: delete non-required instances of include <linux/init.h> 2014-01-08 15:01:39 -08:00
rio500_usb.h
trancevibrator.c usb: delete non-required instances of include <linux/init.h> 2014-01-08 15:01:39 -08:00
usb3503.c usb: misc: usb3503: Use i2c_add_driver helper macro 2015-10-24 19:53:53 -07:00
usb_u132.h
usblcd.c usb: delete non-required instances of include <linux/init.h> 2014-01-08 15:01:39 -08:00
usbled.c usb/misc/usbled: Add Riso Kagaku Webmail Notifier 2014-02-11 14:00:16 -08:00
usbsevseg.c usb: delete non-required instances of include <linux/init.h> 2014-01-08 15:01:39 -08:00
usbtest.c usb: misc: usbtest: add fix for driver hang 2016-09-07 08:32:38 +02:00
uss720.c USB: uss720: fix NULL-deref at probe 2017-03-30 09:35:16 +02:00
yurex.c usb: yurex: fixed sparse warning of incorrect type 2014-11-03 15:34:00 -08:00