linux-stable/drivers/w1/masters
Alan Stern c114944d7d USB: w1 ds2490: Fix bug caused by improper use of altsetting array
The syzkaller USB fuzzer spotted a slab-out-of-bounds bug in the
ds2490 driver.  This bug is caused by improper use of the altsetting
array in the usb_interface structure (the array's entries are not
always stored in numerical order), combined with a naive assumption
that all interfaces probed by the driver will have the expected number
of altsettings.

The bug can be fixed by replacing references to the possibly
non-existent intf->altsetting[alt] entry with the guaranteed-to-exist
intf->cur_altsetting entry.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Reported-and-tested-by: syzbot+d65f673b847a1a96cdba@syzkaller.appspotmail.com
CC: <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-04-25 11:11:41 +02:00
..
ds1wm.c w1: ds1wm: add messages to make incorporation in mfd-drivers easier 2017-08-28 17:20:01 +02:00
ds2482.c w1: ds2482: make module parameter extra_config static 2018-07-03 13:01:48 +02:00
ds2490.c USB: w1 ds2490: Fix bug caused by improper use of altsetting array 2019-04-25 11:11:41 +02:00
Kconfig w1: Allow compile test of GPIO consumers if !GPIOLIB 2018-06-26 09:46:27 +02:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
matrox_w1.c w1: Add subsystem kernel public interface 2017-06-09 11:54:54 +02:00
mxc_w1.c headers: separate linux/mod_devicetable.h from linux/platform_device.h 2018-07-07 17:52:26 +02:00
omap_hdq.c w1: omap-hdq: fix missing bus unregister at removal 2018-10-02 15:36:10 -07:00
w1-gpio.c w1: w1-gpio: Convert to use GPIO descriptors 2017-12-08 15:32:53 +01:00