================================================================== BUG: KASAN: slab-out-of-bounds in _decode_session6+0xf4e/0x1370 net/ipv6/xfrm6_policy.c:137 Read of size 1 at addr ffff8880a8c61f9f by task syz-fuzzer/6495 CPU: 0 PID: 6495 Comm: syz-fuzzer Not tainted 4.19.148-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+0x22c/0x33e lib/dump_stack.c:118 print_address_description.cold+0x56/0x25c mm/kasan/report.c:256 kasan_report_error.cold+0x66/0xb9 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+0xf4e/0x1370 net/ipv6/xfrm6_policy.c:137 __xfrm_decode_session+0x5a/0x150 net/xfrm/xfrm_policy.c:2299 xfrm_decode_session include/net/xfrm.h:1238 [inline] vti6_tnl_xmit+0x42b/0x1cd0 net/ipv6/ip6_vti.c:570 __netdev_start_xmit include/linux/netdevice.h:4333 [inline] netdev_start_xmit include/linux/netdevice.h:4347 [inline] xmit_one net/core/dev.c:3256 [inline] dev_hard_start_xmit+0x1a8/0x960 net/core/dev.c:3272 sch_direct_xmit+0x2cf/0xf70 net/sched/sch_generic.c:332 qdisc_restart net/sched/sch_generic.c:395 [inline] __qdisc_run+0x4fc/0x1670 net/sched/sch_generic.c:403 __dev_xmit_skb net/core/dev.c:3500 [inline] __dev_queue_xmit+0x15ef/0x2ec0 net/core/dev.c:3807 neigh_output include/net/neighbour.h:501 [inline] ip6_finish_output2+0x1184/0x2370 net/ipv6/ip6_output.c:120 ip6_finish_output+0x610/0xcc0 net/ipv6/ip6_output.c:154 NF_HOOK_COND include/linux/netfilter.h:278 [inline] ip6_output+0x205/0x7c0 net/ipv6/ip6_output.c:171 dst_output include/net/dst.h:455 [inline] NF_HOOK include/linux/netfilter.h:289 [inline] ndisc_send_skb+0xa6b/0x1860 net/ipv6/ndisc.c:491 ndisc_send_rs+0x131/0x6a0 net/ipv6/ndisc.c:685 addrconf_rs_timer+0x2d9/0x640 net/ipv6/addrconf.c:3834 call_timer_fn+0x177/0x760 kernel/time/timer.c:1338 expire_timers+0x243/0x500 kernel/time/timer.c:1375 __run_timers kernel/time/timer.c:1703 [inline] run_timer_softirq+0x259/0x730 kernel/time/timer.c:1716 __do_softirq+0x27d/0xad2 kernel/softirq.c:292 invoke_softirq kernel/softirq.c:372 [inline] irq_exit+0x22d/0x270 kernel/softirq.c:412 exiting_irq arch/x86/include/asm/apic.h:544 [inline] smp_apic_timer_interrupt+0x15f/0x5d0 arch/x86/kernel/apic/apic.c:1094 apic_timer_interrupt+0xf/0x20 arch/x86/entry/entry_64.S:894 RIP: 0033:0x40c8f9 Code: 83 8b 02 00 00 48 8b 44 c2 28 4c 8b 58 40 4d 0f bc e3 41 bd 40 00 00 00 4d 0f 44 e5 49 83 fc 40 0f 8d 2d 01 00 00 4c 8b 68 30 <4f> 8d 74 25 00 4c 8b 78 38 4d 39 fe 0f 83 17 01 00 00 4f 8d 6c 25 RSP: 002b:000000c02ccd2a70 EFLAGS: 00000287 ORIG_RAX: ffffffffffffff13 RAX: 00007f8cdc68cc48 RBX: 000000c00003e700 RCX: 000000c000091680 RDX: 00007f8d0c8757d0 RSI: 000000c000091680 RDI: 0000000000000028 RBP: 000000c02ccd2b00 R08: 00000000008eba20 R09: 0000000000203000 R10: 0000000000000008 R11: 00007fffffffffff R12: 0000000000000000 R13: 0000000000000091 R14: 0000000000ae7755 R15: 0000000000000038 Allocated by task 1036: kmem_cache_alloc+0x126/0x4a0 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_symlinkat+0xce/0x2c0 fs/namei.c:4149 do_syscall_64+0xf9/0x670 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 1036: __cache_free mm/slab.c:3503 [inline] kmem_cache_free+0x7f/0x2b0 mm/slab.c:3765 putname+0xe1/0x130 fs/namei.c:261 filename_create+0x22e/0x490 fs/namei.c:3661 user_path_create fs/namei.c:3696 [inline] do_symlinkat+0xe1/0x2c0 fs/namei.c:4149 do_syscall_64+0xf9/0x670 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe The buggy address belongs to the object at ffff8880a8c601c0 which belongs to the cache names_cache of size 4096 The buggy address is located 3551 bytes to the right of 4096-byte region [ffff8880a8c601c0, ffff8880a8c611c0) The buggy address belongs to the page: page:ffffea0002a31800 count:1 mapcount:0 mapping:ffff88821bc44b00 index:0x0 compound_mapcount: 0 flags: 0xfffe0000008100(slab|head) raw: 00fffe0000008100 ffffea0002a3f688 ffffea0002171c08 ffff88821bc44b00 raw: 0000000000000000 ffff8880a8c601c0 0000000100000001 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880a8c61e80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880a8c61f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff8880a8c61f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff8880a8c62000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880a8c62080: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================