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

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Oct 28, 2020 at 04:51:09PM -0400, Kyungtae Kim wrote:
> We report a bug (in linux-5.8.13) found by FuzzUSB (a modified version
> of syzkaller).
> 
> The bug happened when accessing a freed instance of struct fsg_dev
> (i.e., fsg->bulk_in) in do_set_interface() (line 2245).
> 
> ==================================================================
> BUG: KASAN: use-after-free in do_set_interface.part.7+0xa6b/0xd90
> drivers/usb/gadget/function/f_mass_storage.c:2245
> Read of size 8 at addr ffff88806bc940f8 by task file-storage/2063
> 
> CPU: 3 PID: 2063 Comm: file-storage Not tainted 5.8.13 #4
> Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Bochs 01/01/2011
> Call Trace:
>  __dump_stack lib/dump_stack.c:77 [inline]
>  dump_stack+0xa7/0xea lib/dump_stack.c:118
>  print_address_description.constprop.8+0x3f/0x60 mm/kasan/report.c:383
>  kasan_report.cold.11+0x20/0x37 mm/kasan/report.c:513
>  __asan_report_load8_noabort+0x14/0x20 mm/kasan/generic_report.c:146
>  do_set_interface.part.7+0xa6b/0xd90
> drivers/usb/gadget/function/f_mass_storage.c:2245
>  do_set_interface drivers/usb/gadget/function/f_mass_storage.c:2202 [inline]
>  handle_exception drivers/usb/gadget/function/f_mass_storage.c:2426 [inline]
>  fsg_main_thread+0x12c7/0x59f1 drivers/usb/gadget/function/f_mass_storage.c:2466
>  kthread+0x374/0x480 kernel/kthread.c:291
>  ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:293

Is this reproducible?  Can you test patches?

Alan Stern



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux