bisecting fixing commit since b172b44fcb1771e083aad806fa96f3f60e2ddfac building syzkaller on 3ce60af85b4644bd7f2d2ef01a7d2b9a41545b76 testing commit b172b44fcb1771e083aad806fa96f3f60e2ddfac compiler: gcc version 8.4.1 20210217 (GCC) kernel signature: 81fcd80abca68f92eb28b2add49f399035e87dc2ac290411bba5ab168b96fd80 run #0: crashed: KASAN: use-after-free Read in route4_get run #1: crashed: KASAN: use-after-free Read in route4_get run #2: crashed: KASAN: use-after-free Read in route4_get run #3: crashed: KASAN: use-after-free Read in route4_get run #4: crashed: KASAN: use-after-free Read in route4_get run #5: crashed: KASAN: use-after-free Read in route4_get run #6: crashed: KASAN: use-after-free Read in route4_get run #7: crashed: KASAN: use-after-free Read in route4_get run #8: crashed: KASAN: use-after-free Read in route4_get run #9: crashed: KASAN: use-after-free Read in route4_get run #10: crashed: kernel panic: panic_on_warn set run #11: basic kernel testing failed: failed to copy test binary to VM: failed to run ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/tmp/syz-executor040953367" "root@10.128.0.242:./syz-executor040953367"]: exit status 1 Connection timed out during banner exchange Connection to 10.128.0.242 port 22 timed out lost connection run #12: crashed: kernel panic: panic_on_warn set run #13: basic kernel testing failed: failed to copy test binary to VM: timedout ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/tmp/syz-executor350963165" "root@10.128.1.143:./syz-executor350963165"] Warning: Permanently added '10.128.1.143' (ECDSA) to the list of known hosts. run #14: basic kernel testing failed: failed to copy test binary to VM: timedout ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/tmp/syz-executor243926424" "root@10.128.10.36:./syz-executor243926424"] run #15: basic kernel testing failed: failed to copy test binary to VM: timedout ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/tmp/syz-executor239222922" "root@10.128.10.47:./syz-executor239222922"] Warning: Permanently added '10.128.10.47' (ECDSA) to the list of known hosts. run #16: basic kernel testing failed: failed to copy test binary to VM: timedout ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/tmp/syz-executor476202572" "root@10.128.15.195:./syz-executor476202572"] Warning: Permanently added '10.128.15.195' (ECDSA) to the list of known hosts. run #17: basic kernel testing failed: failed to copy test binary to VM: timedout ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/tmp/syz-executor540217147" "root@10.128.15.202:./syz-executor540217147"] Warning: Permanently added '10.128.15.202' (ECDSA) to the list of known hosts. run #18: basic kernel testing failed: failed to copy test binary to VM: timedout ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/tmp/syz-executor017489246" "root@10.128.15.217:./syz-executor017489246"] Warning: Permanently added '10.128.15.217' (ECDSA) to the list of known hosts. run #19: basic kernel testing failed: failed to copy test binary to VM: timedout ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/tmp/syz-executor221304613" "root@10.128.15.220:./syz-executor221304613"] testing current HEAD e34184f53363f6bb873c2fe0ce1a08ed7d16e94a testing commit e34184f53363f6bb873c2fe0ce1a08ed7d16e94a compiler: gcc version 8.4.1 20210217 (GCC) kernel signature: 98280d254d3ca6397eb4389b0acf0391a0386470a16a8672edcf059877937419 run #0: basic kernel testing failed: failed to copy test binary to VM: failed to run ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/syzkaller/jobs/linux/workdir/repro.prog" "root@10.128.15.195:./repro.prog"]: exit status 1 Warning: Permanently added '10.128.15.195' (ECDSA) to the list of known hosts. /syzkaller/jobs/linux/workdir/repro.prog: Broken pipe run #1: crashed: KASAN: use-after-free Read in route4_get run #2: crashed: KASAN: use-after-free Read in route4_get run #3: crashed: KASAN: use-after-free Read in route4_get run #4: crashed: KASAN: use-after-free Read in route4_get run #5: crashed: KASAN: use-after-free Read in route4_get run #6: basic kernel testing failed: failed to copy test binary to VM: failed to run ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/tmp/syz-executor082536095" "root@10.128.15.208:./syz-executor082536095"]: exit status 1 Connection timed out during banner exchange Connection to 10.128.15.208 port 22 timed out lost connection run #7: basic kernel testing failed: failed to copy test binary to VM: failed to run ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/tmp/syz-executor123037554" "root@10.128.15.215:./syz-executor123037554"]: exit status 1 Connection timed out during banner exchange Connection to 10.128.15.215 port 22 timed out lost connection run #8: basic kernel testing failed: failed to copy test binary to VM: failed to run ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/tmp/syz-executor086468137" "root@10.128.15.214:./syz-executor086468137"]: exit status 1 Connection timed out during banner exchange Connection to 10.128.15.214 port 22 timed out lost connection run #9: basic kernel testing failed: failed to copy test binary to VM: failed to run ["scp" "-P" "22" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/tmp/syz-executor740587892" "root@10.128.15.212:./syz-executor740587892"]: exit status 1 Connection timed out during banner exchange Connection to 10.128.15.212 port 22 timed out lost connection revisions tested: 2, total time: 35m24.017017135s (build: 16m3.325109941s, test: 18m58.712613575s) the crash still happens on HEAD commit msg: Linux 4.19.210 crash: KASAN: use-after-free Read in route4_get IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready wlan1: Created IBSS using preconfigured BSSID 50:50:50:50:50:50 wlan1: Creating new IBSS network, BSSID 50:50:50:50:50:50 IPv6: ADDRCONF(NETDEV_CHANGE): wlan1: link becomes ready ================================================================== BUG: KASAN: use-after-free in route4_get+0x2b2/0x2d0 net/sched/cls_route.c:239 Read of size 4 at addr ffff8880a9311940 by task syz-executor.2/10177 CPU: 0 PID: 10177 Comm: syz-executor.2 Not tainted 4.19.210-syzkaller #0 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+0x17c/0x226 lib/dump_stack.c:118 print_address_description.cold.6+0x9/0x211 mm/kasan/report.c:256 kasan_report_error mm/kasan/report.c:354 [inline] kasan_report mm/kasan/report.c:412 [inline] kasan_report.cold.7+0x242/0x2fe mm/kasan/report.c:396 __asan_report_load4_noabort+0x14/0x20 mm/kasan/report.c:432 route4_get+0x2b2/0x2d0 net/sched/cls_route.c:239 tc_new_tfilter+0x48d/0x1560 net/sched/cls_api.c:1300 rtnetlink_rcv_msg+0x34f/0x950 net/core/rtnetlink.c:4782 netlink_rcv_skb+0x13e/0x3d0 net/netlink/af_netlink.c:2457 rtnetlink_rcv+0x10/0x20 net/core/rtnetlink.c:4800 netlink_unicast_kernel net/netlink/af_netlink.c:1320 [inline] netlink_unicast+0x443/0x660 net/netlink/af_netlink.c:1346 netlink_sendmsg+0x667/0xc60 net/netlink/af_netlink.c:1911 sock_sendmsg_nosec net/socket.c:651 [inline] sock_sendmsg+0xac/0xf0 net/socket.c:661 ___sys_sendmsg+0x647/0x950 net/socket.c:2227 __sys_sendmsg+0xd9/0x180 net/socket.c:2265 __do_sys_sendmsg net/socket.c:2274 [inline] __se_sys_sendmsg net/socket.c:2272 [inline] __x64_sys_sendmsg+0x73/0xb0 net/socket.c:2272 do_syscall_64+0xd0/0x4e0 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x4665f9 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 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 73 01 c3 48 c7 c1 bc ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f2e2ea73188 EFLAGS: 00000246 ORIG_RAX: 000000000000002e RAX: ffffffffffffffda RBX: 000000000056c0f0 RCX: 00000000004665f9 RDX: 0000000000000000 RSI: 0000000020000280 RDI: 0000000000000004 RBP: 00000000004bfcc4 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000056c0f0 R13: 00007ffde04cddff R14: 00007f2e2ea73300 R15: 0000000000022000 Allocated by task 10162: save_stack mm/kasan/kasan.c:448 [inline] set_track mm/kasan/kasan.c:460 [inline] kasan_kmalloc.part.1+0x62/0xf0 mm/kasan/kasan.c:553 kasan_kmalloc+0xaf/0xc0 mm/kasan/kasan.c:538 kmem_cache_alloc_trace+0x152/0x3a0 mm/slab.c:3625 kmalloc include/linux/slab.h:515 [inline] kzalloc include/linux/slab.h:709 [inline] route4_change+0x24a/0x1d70 net/sched/cls_route.c:495 tc_new_tfilter+0x61c/0x1560 net/sched/cls_api.c:1320 rtnetlink_rcv_msg+0x34f/0x950 net/core/rtnetlink.c:4782 netlink_rcv_skb+0x13e/0x3d0 net/netlink/af_netlink.c:2457 rtnetlink_rcv+0x10/0x20 net/core/rtnetlink.c:4800 netlink_unicast_kernel net/netlink/af_netlink.c:1320 [inline] netlink_unicast+0x443/0x660 net/netlink/af_netlink.c:1346 netlink_sendmsg+0x667/0xc60 net/netlink/af_netlink.c:1911 sock_sendmsg_nosec net/socket.c:651 [inline] sock_sendmsg+0xac/0xf0 net/socket.c:661 ___sys_sendmsg+0x647/0x950 net/socket.c:2227 __sys_sendmsg+0xd9/0x180 net/socket.c:2265 __do_sys_sendmsg net/socket.c:2274 [inline] __se_sys_sendmsg net/socket.c:2272 [inline] __x64_sys_sendmsg+0x73/0xb0 net/socket.c:2272 do_syscall_64+0xd0/0x4e0 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 37: save_stack mm/kasan/kasan.c:448 [inline] set_track mm/kasan/kasan.c:460 [inline] __kasan_slab_free+0x13c/0x220 mm/kasan/kasan.c:521 kasan_slab_free+0xe/0x10 mm/kasan/kasan.c:528 __cache_free mm/slab.c:3503 [inline] kfree+0xcf/0x220 mm/slab.c:3822 __route4_delete_filter+0x49/0x70 net/sched/cls_route.c:261 route4_delete_filter_work+0x16/0x20 net/sched/cls_route.c:270 process_one_work+0x7b9/0x15a0 kernel/workqueue.c:2153 worker_thread+0x85/0xb60 kernel/workqueue.c:2296 kthread+0x347/0x410 kernel/kthread.c:259 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415 The buggy address belongs to the object at ffff8880a9311900 which belongs to the cache kmalloc-192 of size 192 The buggy address is located 64 bytes inside of 192-byte region [ffff8880a9311900, ffff8880a93119c0) The buggy address belongs to the page: page:ffffea0002a4c440 count:1 mapcount:0 mapping:ffff88813bff6040 index:0x0 flags: 0xfff00000000100(slab) raw: 00fff00000000100 ffffea0002a4c208 ffffea0002a4c7c8 ffff88813bff6040 raw: 0000000000000000 ffff8880a9311000 0000000100000010 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880a9311800: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8880a9311880: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc >ffff8880a9311900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff8880a9311980: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ffff8880a9311a00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================