================================================================== BUG: KASAN: use-after-free in hlist_add_head include/linux/list.h:704 [inline] BUG: KASAN: use-after-free in qdisc_class_hash_insert+0x269/0x280 net/sched/sch_api.c:713 Write of size 8 at addr ffff88809acf9f10 by task syz-executor.4/4398 CPU: 0 PID: 4398 Comm: syz-executor.4 Not tainted 4.19.85-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+0x197/0x210 lib/dump_stack.c:118 print_address_description.cold+0x7c/0x20d 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+0x8c/0x2ba mm/kasan/report.c:396 __asan_report_store8_noabort+0x17/0x20 mm/kasan/report.c:438 hlist_add_head include/linux/list.h:704 [inline] qdisc_class_hash_insert+0x269/0x280 net/sched/sch_api.c:713 qfq_change_class+0xa8d/0x15ce net/sched/sch_qfq.c:501 tc_ctl_tclass+0x4f8/0xc60 net/sched/sch_api.c:1990 rtnetlink_rcv_msg+0x463/0xb00 net/core/rtnetlink.c:4747 netlink_rcv_skb+0x17d/0x460 net/netlink/af_netlink.c:2454 rtnetlink_rcv+0x1d/0x30 net/core/rtnetlink.c:4765 netlink_unicast_kernel net/netlink/af_netlink.c:1317 [inline] netlink_unicast+0x537/0x720 net/netlink/af_netlink.c:1343 netlink_sendmsg+0x8ae/0xd70 net/netlink/af_netlink.c:1908 sock_sendmsg_nosec net/socket.c:622 [inline] sock_sendmsg+0xd7/0x130 net/socket.c:632 ___sys_sendmsg+0x3e2/0x920 net/socket.c:2115 __sys_sendmmsg+0x1bf/0x4e0 net/socket.c:2210 __do_sys_sendmmsg net/socket.c:2239 [inline] __se_sys_sendmmsg net/socket.c:2236 [inline] __x64_sys_sendmmsg+0x9d/0x100 net/socket.c:2236 do_syscall_64+0xfd/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x45a639 Code: ad b6 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 7b b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007f8c1db7dc78 EFLAGS: 00000246 ORIG_RAX: 0000000000000133 RAX: ffffffffffffffda RBX: 00007f8c1db7dc90 RCX: 000000000045a639 RDX: 0000000004924b68 RSI: 0000000020000140 RDI: 0000000000000003 RBP: 000000000075bf20 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00007f8c1db7e6d4 R13: 00000000004c83d1 R14: 00000000004de820 R15: 0000000000000004 Allocated by task 4383: save_stack+0x45/0xd0 mm/kasan/kasan.c:448 set_track mm/kasan/kasan.c:460 [inline] kasan_kmalloc mm/kasan/kasan.c:553 [inline] kasan_kmalloc+0xce/0xf0 mm/kasan/kasan.c:531 kmem_cache_alloc_trace+0x152/0x760 mm/slab.c:3625 kmalloc include/linux/slab.h:515 [inline] kzalloc include/linux/slab.h:709 [inline] qfq_change_class+0x7e1/0x15ce net/sched/sch_qfq.c:476 tc_ctl_tclass+0x4f8/0xc60 net/sched/sch_api.c:1990 rtnetlink_rcv_msg+0x463/0xb00 net/core/rtnetlink.c:4747 netlink_rcv_skb+0x17d/0x460 net/netlink/af_netlink.c:2454 rtnetlink_rcv+0x1d/0x30 net/core/rtnetlink.c:4765 netlink_unicast_kernel net/netlink/af_netlink.c:1317 [inline] netlink_unicast+0x537/0x720 net/netlink/af_netlink.c:1343 netlink_sendmsg+0x8ae/0xd70 net/netlink/af_netlink.c:1908 sock_sendmsg_nosec net/socket.c:622 [inline] sock_sendmsg+0xd7/0x130 net/socket.c:632 ___sys_sendmsg+0x3e2/0x920 net/socket.c:2115 __sys_sendmmsg+0x1bf/0x4e0 net/socket.c:2210 __do_sys_sendmmsg net/socket.c:2239 [inline] __se_sys_sendmmsg net/socket.c:2236 [inline] __x64_sys_sendmmsg+0x9d/0x100 net/socket.c:2236 do_syscall_64+0xfd/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 4383: save_stack+0x45/0xd0 mm/kasan/kasan.c:448 set_track mm/kasan/kasan.c:460 [inline] __kasan_slab_free+0x102/0x150 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 qfq_change_class+0xff7/0x15ce net/sched/sch_qfq.c:530 tc_ctl_tclass+0x4f8/0xc60 net/sched/sch_api.c:1990 rtnetlink_rcv_msg+0x463/0xb00 net/core/rtnetlink.c:4747 netlink_rcv_skb+0x17d/0x460 net/netlink/af_netlink.c:2454 rtnetlink_rcv+0x1d/0x30 net/core/rtnetlink.c:4765 netlink_unicast_kernel net/netlink/af_netlink.c:1317 [inline] netlink_unicast+0x537/0x720 net/netlink/af_netlink.c:1343 netlink_sendmsg+0x8ae/0xd70 net/netlink/af_netlink.c:1908 sock_sendmsg_nosec net/socket.c:622 [inline] sock_sendmsg+0xd7/0x130 net/socket.c:632 ___sys_sendmsg+0x3e2/0x920 net/socket.c:2115 __sys_sendmmsg+0x1bf/0x4e0 net/socket.c:2210 __do_sys_sendmmsg net/socket.c:2239 [inline] __se_sys_sendmmsg net/socket.c:2236 [inline] __x64_sys_sendmmsg+0x9d/0x100 net/socket.c:2236 do_syscall_64+0xfd/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe The buggy address belongs to the object at ffff88809acf9f00 which belongs to the cache kmalloc-128 of size 128 The buggy address is located 16 bytes inside of 128-byte region [ffff88809acf9f00, ffff88809acf9f80) The buggy address belongs to the page: page:ffffea00026b3e40 count:1 mapcount:0 mapping:ffff88812c3f0640 index:0x0 flags: 0x1fffc0000000100(slab) raw: 01fffc0000000100 ffffea00025bd948 ffffea00026601c8 ffff88812c3f0640 raw: 0000000000000000 ffff88809acf9000 0000000100000015 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff88809acf9e00: fc fc fc fc fc fc fc fc 00 00 00 00 00 00 00 00 ffff88809acf9e80: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc >ffff88809acf9f00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff88809acf9f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88809acfa000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================