================================================================== BUG: KASAN: stack-out-of-bounds in jhash2 include/linux/jhash.h:138 [inline] BUG: KASAN: stack-out-of-bounds in __xfrm6_addr_hash net/xfrm/xfrm_hash.h:16 [inline] BUG: KASAN: stack-out-of-bounds in __xfrm6_daddr_saddr_hash net/xfrm/xfrm_hash.h:29 [inline] BUG: KASAN: stack-out-of-bounds in __xfrm_dst_hash net/xfrm/xfrm_hash.h:95 [inline] BUG: KASAN: stack-out-of-bounds in xfrm_dst_hash net/xfrm/xfrm_state.c:64 [inline] BUG: KASAN: stack-out-of-bounds in xfrm_state_find+0x5f79/0x6d80 net/xfrm/xfrm_state.c:1159 Read of size 4 at addr ffffc90000007ad0 by task dhcpcd/4648 CPU: 0 PID: 4648 Comm: dhcpcd Not tainted 6.1.0-syzkaller-11778-gc183e6c3ec34 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xd1/0x138 lib/dump_stack.c:106 print_address_description mm/kasan/report.c:306 [inline] print_report+0x15e/0x45d mm/kasan/report.c:417 kasan_report+0xbf/0x1f0 mm/kasan/report.c:517 jhash2 include/linux/jhash.h:138 [inline] __xfrm6_addr_hash net/xfrm/xfrm_hash.h:16 [inline] __xfrm6_daddr_saddr_hash net/xfrm/xfrm_hash.h:29 [inline] __xfrm_dst_hash net/xfrm/xfrm_hash.h:95 [inline] xfrm_dst_hash net/xfrm/xfrm_state.c:64 [inline] xfrm_state_find+0x5f79/0x6d80 net/xfrm/xfrm_state.c:1159 xfrm_tmpl_resolve_one net/xfrm/xfrm_policy.c:2467 [inline] xfrm_tmpl_resolve+0x2f3/0xd40 net/xfrm/xfrm_policy.c:2512 xfrm_resolve_and_create_bundle+0x123/0x2580 net/xfrm/xfrm_policy.c:2805 xfrm_bundle_lookup net/xfrm/xfrm_policy.c:3040 [inline] xfrm_lookup_with_ifid+0x449/0x20f0 net/xfrm/xfrm_policy.c:3171 xfrm_lookup net/xfrm/xfrm_policy.c:3268 [inline] xfrm_lookup_route+0x3a/0x1e0 net/xfrm/xfrm_policy.c:3279 ip_route_output_flow+0x118/0x150 net/ipv4/route.c:2880 ip_route_output_ports include/net/route.h:183 [inline] igmpv3_newpack+0x29d/0x1110 net/ipv4/igmp.c:369 add_grhead+0x266/0x300 net/ipv4/igmp.c:440 add_grec+0xea5/0x1100 net/ipv4/igmp.c:574 igmpv3_send_cr net/ipv4/igmp.c:711 [inline] igmp_ifc_timer_expire+0x636/0xf70 net/ipv4/igmp.c:810 call_timer_fn+0x1da/0x7c0 kernel/time/timer.c:1700 expire_timers+0x2c6/0x5c0 kernel/time/timer.c:1751 __run_timers kernel/time/timer.c:2022 [inline] __run_timers kernel/time/timer.c:1995 [inline] run_timer_softirq+0x326/0x910 kernel/time/timer.c:2035 __do_softirq+0x1fb/0xadc kernel/softirq.c:571 invoke_softirq kernel/softirq.c:445 [inline] __irq_exit_rcu+0x123/0x180 kernel/softirq.c:650 irq_exit_rcu+0x9/0x20 kernel/softirq.c:662 sysvec_apic_timer_interrupt+0x97/0xc0 arch/x86/kernel/apic/apic.c:1107 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:649 RIP: 0010:skb_trim+0x3d/0x170 net/core/skbuff.c:2293 Code: 8d 7b 70 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 0f b6 04 02 84 c0 74 08 3c 03 0f 8e f2 00 00 00 44 8b 63 70 89 ee <44> 89 e7 e8 9b 77 c0 f9 41 39 ec 77 09 5b 5d 41 5c e9 5d 7b c0 f9 RSP: 0018:ffffc9000331f238 EFLAGS: 00000246 RAX: 0000000000000000 RBX: ffff88801ea0aa00 RCX: 0000000000000000 RDX: 1ffff11003d4154e RSI: 0000000000000b40 RDI: ffff88801ea0aa70 RBP: 0000000000000b40 R08: 0000000000000005 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000b44 R13: dffffc0000000000 R14: ffff88801ea0aa00 R15: ffff88814a460000 nlmsg_trim include/net/netlink.h:1041 [inline] nla_nest_cancel include/net/netlink.h:1863 [inline] rtnl_fill_prop_list net/core/rtnetlink.c:1710 [inline] rtnl_fill_ifinfo+0x3b81/0x4670 net/core/rtnetlink.c:1891 rtnl_dump_ifinfo+0xb06/0x14a0 net/core/rtnetlink.c:2226 netlink_dump+0x570/0xc50 net/netlink/af_netlink.c:2286 netlink_recvmsg+0xbe1/0xe50 net/netlink/af_netlink.c:2013 sock_recvmsg_nosec net/socket.c:995 [inline] sock_recvmsg net/socket.c:1013 [inline] sock_recvmsg net/socket.c:1009 [inline] ____sys_recvmsg+0x2c7/0x610 net/socket.c:2695 ___sys_recvmsg+0xf2/0x180 net/socket.c:2737 __sys_recvmsg+0xf4/0x1c0 net/socket.c:2767 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x39/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7fb71ddeb003 Code: 8b 15 79 fe 0b 00 f7 d8 64 89 02 48 c7 c0 ff ff ff ff eb b5 0f 1f 00 64 8b 04 25 18 00 00 00 85 c0 75 14 b8 2f 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 55 c3 0f 1f 40 00 48 83 ec 28 89 54 24 1c 48 RSP: 002b:00007fffcf02d638 EFLAGS: 00000246 ORIG_RAX: 000000000000002f RAX: ffffffffffffffda RBX: 00007fffcf02e770 RCX: 00007fb71ddeb003 RDX: 0000000000000000 RSI: 00007fffcf02e690 RDI: 0000000000000018 RBP: 00007fffcf02e700 R08: 0000000000000000 R09: 00007fb71deaba60 R10: 0000000000100000 R11: 0000000000000246 R12: 00007fffcf02e690 R13: 00007fffcf02e674 R14: 00007fffcf02e680 R15: 0000000000000b18 The buggy address belongs to the virtual mapping at [ffffc90000000000, ffffc90000009000) created by: map_irq_stack arch/x86/kernel/irq_64.c:48 [inline] irq_init_percpu_irqstack+0x1d0/0x320 arch/x86/kernel/irq_64.c:75 The buggy address belongs to the physical page: page:ffffea0002e60240 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0xb9809 flags: 0xfff00000001000(reserved|node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000001000 ffffea0002e60248 ffffea0002e60248 0000000000000000 raw: 0000000000000000 0000000000000000 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner info is not present (never set?) Memory state around the buggy address: ffffc90000007980: 00 f3 f3 00 00 00 00 00 00 00 00 00 00 00 00 00 ffffc90000007a00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 f1 f1 >ffffc90000007a80: f1 f1 00 00 00 00 00 00 00 00 f3 f3 f3 f3 00 00 ^ ffffc90000007b00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffffc90000007b80: 00 00 00 00 00 00 00 00 00 00 00 00 00 f1 f1 f1 ================================================================== ---------------- Code disassembly (best guess): 0: 8d 7b 70 lea 0x70(%rbx),%edi 3: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax a: fc ff df d: 48 89 fa mov %rdi,%rdx 10: 48 c1 ea 03 shr $0x3,%rdx 14: 0f b6 04 02 movzbl (%rdx,%rax,1),%eax 18: 84 c0 test %al,%al 1a: 74 08 je 0x24 1c: 3c 03 cmp $0x3,%al 1e: 0f 8e f2 00 00 00 jle 0x116 24: 44 8b 63 70 mov 0x70(%rbx),%r12d 28: 89 ee mov %ebp,%esi * 2a: 44 89 e7 mov %r12d,%edi <-- trapping instruction 2d: e8 9b 77 c0 f9 callq 0xf9c077cd 32: 41 39 ec cmp %ebp,%r12d 35: 77 09 ja 0x40 37: 5b pop %rbx 38: 5d pop %rbp 39: 41 5c pop %r12 3b: e9 5d 7b c0 f9 jmpq 0xf9c07b9d