Re: KASAN: use-after-free Read in dvb_usb_device_exit

From: Oliver Neukum
Date: Mon Apr 15 2019 - 07:12:42 EST


On Fr, 2019-04-12 at 04:46 -0700, syzbot wrote:
> Hello,
>
> syzbot found the following crash on:
>
> HEAD commit: 9a33b369 usb-fuzzer: main usb gadget fuzzer driver
> git tree: https://github.com/google/kasan/tree/usb-fuzzer
> console output: https://syzkaller.appspot.com/x/log.txt?x=1643974b200000
> kernel config: https://syzkaller.appspot.com/x/.config?x=23e37f59d94ddd15
> dashboard link: https://syzkaller.appspot.com/bug?extid=26ec41e9f788b3eba396
> compiler: gcc (GCC) 9.0.0 20181231 (experimental)
> syz repro: https://syzkaller.appspot.com/x/repro.syz?x=12f5efa7200000
> C reproducer: https://syzkaller.appspot.com/x/repro.c?x=1395a0f3200000
>
> IMPORTANT: if you fix the bug, please add the following tag to the commit:
> Reported-by: syzbot+26ec41e9f788b3eba396@xxxxxxxxxxxxxxxxxxxxxxxxx
>
> dvb-usb: schedule remote query interval to 150 msecs.
> dw2102: su3000_power_ctrl: 0, initialized 1
> dvb-usb: TeVii S421 PCI successfully initialized and connected.
> usb 1-1: USB disconnect, device number 2

Hi,

proposed fix. If nobody objects, I will submit it.

Regards
Oliver