================================================================== BUG: KASAN: use-after-free in thread_group_leader include/linux/sched/signal.h:631 [inline] BUG: KASAN: use-after-free in css_task_iter_advance+0x4a5/0x540 kernel/cgroup/cgroup.c:4499 Read of size 4 at addr ffff8880a0be5434 by task syz-executor.0/30011 CPU: 0 PID: 30011 Comm: syz-executor.0 Not tainted 5.2.0-rc3-next-20190606 #10 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x172/0x1f0 lib/dump_stack.c:113 print_address_description.cold+0xd4/0x306 mm/kasan/report.c:351 __kasan_report.cold+0x1b/0x36 mm/kasan/report.c:482 kasan_report+0x12/0x20 mm/kasan/common.c:614 __asan_report_load4_noabort+0x14/0x20 mm/kasan/generic_report.c:131 thread_group_leader include/linux/sched/signal.h:631 [inline] css_task_iter_advance+0x4a5/0x540 kernel/cgroup/cgroup.c:4499 css_task_iter_start+0x18b/0x230 kernel/cgroup/cgroup.c:4543 __cgroup_procs_start.isra.0+0x32f/0x400 kernel/cgroup/cgroup.c:4638 cgroup_procs_start kernel/cgroup/cgroup.c:4660 [inline] cgroup_procs_start+0x1e7/0x260 kernel/cgroup/cgroup.c:4647 cgroup_seqfile_start+0xa4/0xd0 kernel/cgroup/cgroup.c:3752 kernfs_seq_start+0xdc/0x190 fs/kernfs/file.c:118 traverse fs/seq_file.c:108 [inline] traverse+0x165/0x740 fs/seq_file.c:91 seq_read+0x8dd/0x1110 fs/seq_file.c:188 kernfs_fop_read+0xed/0x560 fs/kernfs/file.c:252 do_loop_readv_writev fs/read_write.c:714 [inline] do_loop_readv_writev fs/read_write.c:701 [inline] do_iter_read+0x4a4/0x660 fs/read_write.c:935 vfs_readv+0xf0/0x160 fs/read_write.c:997 kernel_readv fs/splice.c:359 [inline] default_file_splice_read+0x475/0x890 fs/splice.c:414 do_splice_to+0x127/0x180 fs/splice.c:877 splice_direct_to_actor+0x2d2/0x970 fs/splice.c:954 do_splice_direct+0x1da/0x2a0 fs/splice.c:1063 do_sendfile+0x597/0xd00 fs/read_write.c:1464 __do_sys_sendfile64 fs/read_write.c:1525 [inline] __se_sys_sendfile64 fs/read_write.c:1511 [inline] __x64_sys_sendfile64+0x1dd/0x220 fs/read_write.c:1511 do_syscall_64+0xfd/0x680 arch/x86/entry/common.c:301 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x459279 Code: fd b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 0f 83 cb b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007fd787448c78 EFLAGS: 00000246 ORIG_RAX: 0000000000000028 RAX: ffffffffffffffda RBX: 0000000000000004 RCX: 0000000000459279 RDX: 0000000000000000 RSI: 0000000000000004 RDI: 0000000000000004 RBP: 000000000075bf20 R08: 0000000000000000 R09: 0000000000000000 R10: 00000000000001ff R11: 0000000000000246 R12: 00007fd7874496d4 R13: 00000000004c65f3 R14: 00000000004db2a8 R15: 00000000ffffffff Allocated by task 28067: save_stack+0x23/0x90 mm/kasan/common.c:71 set_track mm/kasan/common.c:79 [inline] __kasan_kmalloc mm/kasan/common.c:489 [inline] __kasan_kmalloc.constprop.0+0xcf/0xe0 mm/kasan/common.c:462 kasan_kmalloc+0x9/0x10 mm/kasan/common.c:503 kmem_cache_alloc_trace+0x151/0x750 mm/slab.c:3549 kmalloc include/linux/slab.h:547 [inline] kzalloc include/linux/slab.h:742 [inline] alloc_super+0x55/0x890 fs/super.c:202 sget_userns+0xf1/0x560 fs/super.c:609 sget+0x10c/0x150 fs/super.c:660 mount_bdev+0xff/0x3c0 fs/super.c:1319 ext4_mount+0x35/0x40 fs/ext4/super.c:6007 legacy_get_tree+0x108/0x220 fs/fs_context.c:661 vfs_get_tree+0x8e/0x390 fs/super.c:1476 do_new_mount fs/namespace.c:2790 [inline] do_mount+0x138c/0x1c00 fs/namespace.c:3110 ksys_mount+0xdb/0x150 fs/namespace.c:3319 __do_sys_mount fs/namespace.c:3333 [inline] __se_sys_mount fs/namespace.c:3330 [inline] __x64_sys_mount+0xbe/0x150 fs/namespace.c:3330 do_syscall_64+0xfd/0x680 arch/x86/entry/common.c:301 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 17: save_stack+0x23/0x90 mm/kasan/common.c:71 set_track mm/kasan/common.c:79 [inline] __kasan_slab_free+0x102/0x150 mm/kasan/common.c:451 kasan_slab_free+0xe/0x10 mm/kasan/common.c:459 __cache_free mm/slab.c:3426 [inline] kfree+0x106/0x2a0 mm/slab.c:3753 destroy_super_work+0x42/0x50 fs/super.c:164 process_one_work+0x989/0x1790 kernel/workqueue.c:2269 worker_thread+0x98/0xe40 kernel/workqueue.c:2415 kthread+0x354/0x420 kernel/kthread.c:255 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:352 The buggy address belongs to the object at ffff8880a0be4780 which belongs to the cache kmalloc-4k of size 4096 The buggy address is located 3252 bytes inside of 4096-byte region [ffff8880a0be4780, ffff8880a0be5780) The buggy address belongs to the page: page:ffffea000282f900 refcount:1 mapcount:0 mapping:ffff8880aa400dc0 index:0x0 compound_mapcount: 0 flags: 0x1fffc0000010200(slab|head) raw: 01fffc0000010200 ffffea00010fe088 ffffea0002387808 ffff8880aa400dc0 raw: 0000000000000000 ffff8880a0be4780 0000000100000001 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880a0be5300: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8880a0be5380: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb >ffff8880a0be5400: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff8880a0be5480: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8880a0be5500: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================