================================================================== BUG: KASAN: slab-out-of-bounds in _decode_session6+0xf56/0x1370 net/ipv6/xfrm6_policy.c:137 Read of size 1 at addr ffff88809e4141f7 by task syz-executor.1/12327 CPU: 0 PID: 12327 Comm: syz-executor.1 Not tainted 4.19.130-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+0x1fc/0x2fe lib/dump_stack.c:118 print_address_description.cold+0x54/0x219 mm/kasan/report.c:256 kasan_report_error.cold+0x8a/0x1c7 mm/kasan/report.c:354 kasan_report mm/kasan/report.c:412 [inline] __asan_report_load1_noabort+0x88/0x90 mm/kasan/report.c:430 _decode_session6+0xf56/0x1370 net/ipv6/xfrm6_policy.c:137 __xfrm_decode_session+0x5a/0x130 net/xfrm/xfrm_policy.c:2299 xfrm_decode_session_reverse include/net/xfrm.h:1244 [inline] icmpv6_route_lookup+0x2fb/0x460 net/ipv6/icmp.c:372 icmp6_send+0x150d/0x2230 net/ipv6/icmp.c:555 icmpv6_send+0xde/0x210 net/ipv6/ip6_icmp.c:43 ip6_link_failure+0x26/0x4e0 net/ipv6/route.c:2297 dst_link_failure include/net/dst.h:430 [inline] ipip6_tunnel_xmit net/ipv6/sit.c:1001 [inline] sit_tunnel_xmit+0x1967/0x2810 net/ipv6/sit.c:1038 __netdev_start_xmit include/linux/netdevice.h:4314 [inline] netdev_start_xmit include/linux/netdevice.h:4323 [inline] xmit_one net/core/dev.c:3256 [inline] dev_hard_start_xmit+0x1a8/0x920 net/core/dev.c:3272 sch_direct_xmit+0x2d6/0xf50 net/sched/sch_generic.c:332 qdisc_restart net/sched/sch_generic.c:395 [inline] __qdisc_run+0x4d0/0x1630 net/sched/sch_generic.c:403 __dev_xmit_skb net/core/dev.c:3500 [inline] __dev_queue_xmit+0x1516/0x2df0 net/core/dev.c:3810 neigh_output include/net/neighbour.h:501 [inline] ip6_finish_output2+0x113d/0x2290 net/ipv6/ip6_output.c:120 ip6_finish_output+0x7e9/0xc00 net/ipv6/ip6_output.c:154 NF_HOOK_COND include/linux/netfilter.h:278 [inline] ip6_output+0x205/0x770 net/ipv6/ip6_output.c:171 dst_output include/net/dst.h:447 [inline] NF_HOOK include/linux/netfilter.h:289 [inline] ip6_xmit+0xdbf/0x20a0 net/ipv6/ip6_output.c:275 sctp_v6_xmit+0x32d/0x640 net/sctp/ipv6.c:229 sctp_packet_transmit+0x1bf6/0x3270 net/sctp/output.c:641 sctp_packet_singleton net/sctp/outqueue.c:791 [inline] sctp_outq_flush_ctrl.constprop.0+0x6d3/0xc40 net/sctp/outqueue.c:922 sctp_outq_flush net/sctp/outqueue.c:1204 [inline] sctp_outq_uncork+0x10b/0x200 net/sctp/outqueue.c:776 sctp_cmd_interpreter net/sctp/sm_sideeffect.c:1815 [inline] sctp_side_effects net/sctp/sm_sideeffect.c:1199 [inline] sctp_do_sm+0x4d5/0x4e50 net/sctp/sm_sideeffect.c:1170 sctp_primitive_ASSOCIATE+0x98/0xc0 net/sctp/primitive.c:88 __sctp_connect+0x903/0xd40 net/sctp/socket.c:1244 sctp_connect net/sctp/socket.c:4520 [inline] sctp_inet_connect+0x14b/0x1b0 net/sctp/socket.c:4535 __sys_connect+0x265/0x2c0 net/socket.c:1663 __do_sys_connect net/socket.c:1674 [inline] __se_sys_connect net/socket.c:1671 [inline] __x64_sys_connect+0x6f/0xb0 net/socket.c:1671 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x45cb19 Code: 0d 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 db b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007f4e347aec78 EFLAGS: 00000246 ORIG_RAX: 000000000000002a RAX: ffffffffffffffda RBX: 00000000004db880 RCX: 000000000045cb19 RDX: 000000000000001c RSI: 0000000020000080 RDI: 0000000000000003 RBP: 000000000078c040 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00000000ffffffff R13: 000000000000008a R14: 00000000004c353e R15: 00007f4e347af6d4 Allocated by task 3677: kmem_cache_alloc+0x122/0x370 mm/slab.c:3559 getname_flags+0xce/0x590 fs/namei.c:140 getname fs/namei.c:211 [inline] user_path_create fs/namei.c:3696 [inline] do_mkdirat+0x8d/0x2d0 fs/namei.c:3834 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 3677: __cache_free mm/slab.c:3503 [inline] kmem_cache_free+0x7f/0x260 mm/slab.c:3765 putname+0xe1/0x120 fs/namei.c:261 filename_parentat+0x4da/0x590 fs/namei.c:2399 filename_create+0x9e/0x490 fs/namei.c:3621 user_path_create fs/namei.c:3696 [inline] do_mkdirat+0xa0/0x2d0 fs/namei.c:3834 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe The buggy address belongs to the object at ffff88809e414780 which belongs to the cache names_cache of size 4096 The buggy address is located 1417 bytes to the left of 4096-byte region [ffff88809e414780, ffff88809e415780) The buggy address belongs to the page: page:ffffea0002790500 count:1 mapcount:0 mapping:ffff8880aa00ab40 index:0x0 compound_mapcount: 0 flags: 0xfffe0000008100(slab|head) raw: 00fffe0000008100 ffffea000143a688 ffffea0002790588 ffff8880aa00ab40 raw: 0000000000000000 ffff88809e414780 0000000100000001 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff88809e414080: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88809e414100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff88809e414180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff88809e414200: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88809e414280: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================