================================================================== BUG: KASAN: use-after-free in kfree_skb_list+0x4c/0x50 net/core/skbuff.c:705 Read of size 8 at addr ffff888085ec3480 by task syz-executor.5/7463 CPU: 0 PID: 7463 Comm: syz-executor.5 Not tainted 5.2.0-rc1+ #1 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+0x113/0x167 lib/dump_stack.c:113 print_address_description.cold.5+0x9/0x1ff mm/kasan/report.c:188 __kasan_report.cold.6+0x1b/0x39 mm/kasan/report.c:317 kasan_report+0x12/0x20 mm/kasan/common.c:614 __asan_report_load8_noabort+0x14/0x20 mm/kasan/generic_report.c:132 kfree_skb_list+0x4c/0x50 net/core/skbuff.c:705 ip6_fragment+0x1ed1/0x2e50 net/ipv6/ip6_output.c:778 ip6_finish_output+0x536/0xa50 net/ipv6/ip6_output.c:152 NF_HOOK_COND include/linux/netfilter.h:294 [inline] ip6_output+0x1bf/0x630 net/ipv6/ip6_output.c:171 dst_output include/net/dst.h:433 [inline] ip6_local_out+0x78/0x130 net/ipv6/output_core.c:179 ip6_send_skb+0x92/0x2f0 net/ipv6/ip6_output.c:1757 ip6_push_pending_frames+0x94/0xb0 net/ipv6/ip6_output.c:1777 rawv6_push_pending_frames net/ipv6/raw.c:617 [inline] rawv6_sendmsg+0x240a/0x3250 net/ipv6/raw.c:947 inet_sendmsg+0x108/0x460 net/ipv4/af_inet.c:802 sock_sendmsg_nosec net/socket.c:652 [inline] sock_sendmsg+0xb5/0xf0 net/socket.c:671 ___sys_sendmsg+0x647/0x950 net/socket.c:2292 __sys_sendmsg+0xd9/0x180 net/socket.c:2330 __do_sys_sendmsg net/socket.c:2339 [inline] __se_sys_sendmsg net/socket.c:2337 [inline] __x64_sys_sendmsg+0x73/0xb0 net/socket.c:2337 do_syscall_64+0xd0/0x530 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:00007efcc4c0dc78 EFLAGS: 00000246 ORIG_RAX: 000000000000002e RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 0000000000459279 RDX: 0000000000000000 RSI: 0000000020000240 RDI: 0000000000000005 RBP: 000000000075bf20 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00007efcc4c0e6d4 R13: 00000000004c6c94 R14: 00000000004dba90 R15: 00000000ffffffff Allocated by task 7463: save_stack+0x21/0x90 mm/kasan/common.c:71 set_track mm/kasan/common.c:79 [inline] __kasan_kmalloc.constprop.8+0xc7/0xd0 mm/kasan/common.c:489 kasan_slab_alloc+0x12/0x20 mm/kasan/common.c:497 slab_post_alloc_hook mm/slab.h:437 [inline] slab_alloc_node mm/slab.c:3269 [inline] kmem_cache_alloc_node+0x131/0x720 mm/slab.c:3579 __alloc_skb+0xa7/0x570 net/core/skbuff.c:198 alloc_skb include/linux/skbuff.h:1058 [inline] __ip6_append_data.isra.51+0x2397/0x37e0 net/ipv6/ip6_output.c:1480 ip6_append_data+0x165/0x2f0 net/ipv6/ip6_output.c:1649 rawv6_sendmsg+0x1934/0x3250 net/ipv6/raw.c:940 inet_sendmsg+0x108/0x460 net/ipv4/af_inet.c:802 sock_sendmsg_nosec net/socket.c:652 [inline] sock_sendmsg+0xb5/0xf0 net/socket.c:671 ___sys_sendmsg+0x647/0x950 net/socket.c:2292 __sys_sendmsg+0xd9/0x180 net/socket.c:2330 __do_sys_sendmsg net/socket.c:2339 [inline] __se_sys_sendmsg net/socket.c:2337 [inline] __x64_sys_sendmsg+0x73/0xb0 net/socket.c:2337 do_syscall_64+0xd0/0x530 arch/x86/entry/common.c:301 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 7463: save_stack+0x21/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:3432 [inline] kmem_cache_free+0x83/0x290 mm/slab.c:3698 kfree_skbmem+0x82/0xf0 net/core/skbuff.c:624 __kfree_skb net/core/skbuff.c:681 [inline] kfree_skb+0x9f/0x270 net/core/skbuff.c:698 ip6_tnl_start_xmit+0x270/0x1ec0 net/ipv6/ip6_tunnel.c:1423 __netdev_start_xmit include/linux/netdevice.h:4410 [inline] netdev_start_xmit include/linux/netdevice.h:4424 [inline] xmit_one net/core/dev.c:3292 [inline] dev_hard_start_xmit+0x144/0x750 net/core/dev.c:3308 __dev_queue_xmit+0x1feb/0x2ff0 net/core/dev.c:3881 dev_queue_xmit+0xb/0x10 net/core/dev.c:3914 neigh_direct_output+0xc/0x10 net/core/neighbour.c:1532 neigh_output include/net/neighbour.h:511 [inline] ip6_finish_output2+0xc68/0x22f0 net/ipv6/ip6_output.c:120 ip6_fragment+0x1ea7/0x2e50 net/ipv6/ip6_output.c:759 ip6_finish_output+0x536/0xa50 net/ipv6/ip6_output.c:152 NF_HOOK_COND include/linux/netfilter.h:294 [inline] ip6_output+0x1bf/0x630 net/ipv6/ip6_output.c:171 dst_output include/net/dst.h:433 [inline] ip6_local_out+0x78/0x130 net/ipv6/output_core.c:179 ip6_send_skb+0x92/0x2f0 net/ipv6/ip6_output.c:1757 ip6_push_pending_frames+0x94/0xb0 net/ipv6/ip6_output.c:1777 rawv6_push_pending_frames net/ipv6/raw.c:617 [inline] rawv6_sendmsg+0x240a/0x3250 net/ipv6/raw.c:947 inet_sendmsg+0x108/0x460 net/ipv4/af_inet.c:802 sock_sendmsg_nosec net/socket.c:652 [inline] sock_sendmsg+0xb5/0xf0 net/socket.c:671 ___sys_sendmsg+0x647/0x950 net/socket.c:2292 __sys_sendmsg+0xd9/0x180 net/socket.c:2330 __do_sys_sendmsg net/socket.c:2339 [inline] __se_sys_sendmsg net/socket.c:2337 [inline] __x64_sys_sendmsg+0x73/0xb0 net/socket.c:2337 do_syscall_64+0xd0/0x530 arch/x86/entry/common.c:301 entry_SYSCALL_64_after_hwframe+0x49/0xbe The buggy address belongs to the object at ffff888085ec3480 which belongs to the cache skbuff_head_cache of size 224 The buggy address is located 0 bytes inside of 224-byte region [ffff888085ec3480, ffff888085ec3560) The buggy address belongs to the page: page:ffffea000217b0c0 refcount:1 mapcount:0 mapping:ffff88821b6f6540 index:0x0 flags: 0x1fffc0000000200(slab) raw: 01fffc0000000200 ffffea00024dd208 ffffea000240b808 ffff88821b6f6540 raw: 0000000000000000 ffff888085ec30c0 000000010000000c 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff888085ec3380: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff888085ec3400: fb fb fb fb fc fc fc fc fc fc fc fc fc fc fc fc >ffff888085ec3480: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff888085ec3500: fb fb fb fb fb fb fb fb fb fb fb fb fc fc fc fc ffff888085ec3580: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb ==================================================================