================================================================== BUG: KASAN: slab-out-of-bounds in do_csum+0x44/0x254 arch/arm64/lib/csum.c:39 Read of size 4294966032 at addr ffff0000ceecc4f0 by task syz-executor.2/15275 CPU: 0 PID: 15275 Comm: syz-executor.2 Not tainted 6.5.0-rc7-syzkaller-g35e2132122ba #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023 Call trace: dump_backtrace+0x1b8/0x1e4 arch/arm64/kernel/stacktrace.c:233 show_stack+0x2c/0x44 arch/arm64/kernel/stacktrace.c:240 __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xd0/0x124 lib/dump_stack.c:106 print_address_description mm/kasan/report.c:364 [inline] print_report+0x174/0x514 mm/kasan/report.c:475 kasan_report+0xd8/0x138 mm/kasan/report.c:588 kasan_check_range+0x254/0x294 mm/kasan/generic.c:187 __kasan_check_read+0x20/0x30 mm/kasan/shadow.c:31 do_csum+0x44/0x254 arch/arm64/lib/csum.c:39 csum_partial+0x30/0x58 lib/checksum.c:128 gso_make_checksum include/net/gso.h:74 [inline] __udp_gso_segment+0xba4/0x1c98 net/ipv4/udp_offload.c:340 udp6_ufo_fragment+0x4dc/0xc48 net/ipv6/udp_offload.c:47 ipv6_gso_segment+0x5cc/0x1760 net/ipv6/ip6_offload.c:120 skb_mac_gso_segment+0x2d0/0x5bc net/core/gso.c:53 __skb_gso_segment+0x250/0x3cc net/core/gso.c:124 skb_gso_segment include/net/gso.h:83 [inline] validate_xmit_skb+0x3cc/0xe54 net/core/dev.c:3618 validate_xmit_skb_list net/core/dev.c:3668 [inline] __dev_direct_xmit+0x164/0x874 net/core/dev.c:4247 dev_direct_xmit include/linux/netdevice.h:3101 [inline] packet_xmit+0x1a4/0x318 net/packet/af_packet.c:285 packet_snd net/packet/af_packet.c:3085 [inline] packet_sendmsg+0x376c/0x4c98 net/packet/af_packet.c:3117 sock_sendmsg_nosec net/socket.c:725 [inline] sock_sendmsg net/socket.c:748 [inline] __sys_sendto+0x3bc/0x540 net/socket.c:2134 __do_sys_sendto net/socket.c:2146 [inline] __se_sys_sendto net/socket.c:2142 [inline] __arm64_sys_sendto+0xd8/0xf8 net/socket.c:2142 __invoke_syscall arch/arm64/kernel/syscall.c:37 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:51 el0_svc_common+0x130/0x23c arch/arm64/kernel/syscall.c:136 do_el0_svc+0x48/0x58 arch/arm64/kernel/syscall.c:155 el0_svc+0x58/0x16c arch/arm64/kernel/entry-common.c:678 el0t_64_sync_handler+0x84/0xfc arch/arm64/kernel/entry-common.c:696 el0t_64_sync+0x190/0x194 arch/arm64/kernel/entry.S:591 Allocated by task 15275: kasan_save_stack mm/kasan/common.c:45 [inline] kasan_set_track+0x4c/0x7c mm/kasan/common.c:52 kasan_save_alloc_info+0x24/0x30 mm/kasan/generic.c:511 ____kasan_kmalloc mm/kasan/common.c:374 [inline] __kasan_kmalloc+0xac/0xc4 mm/kasan/common.c:383 kasan_kmalloc include/linux/kasan.h:196 [inline] __do_kmalloc_node mm/slab_common.c:985 [inline] __kmalloc_node_track_caller+0xd0/0x1c0 mm/slab_common.c:1005 kmalloc_reserve+0x120/0x240 net/core/skbuff.c:575 __alloc_skb+0x1c8/0x3d8 net/core/skbuff.c:644 skb_segment+0xa80/0x32ec net/core/skbuff.c:4512 __udp_gso_segment+0x344/0x1c98 net/ipv4/udp_offload.c:298 udp6_ufo_fragment+0x4dc/0xc48 net/ipv6/udp_offload.c:47 ipv6_gso_segment+0x5cc/0x1760 net/ipv6/ip6_offload.c:120 skb_mac_gso_segment+0x2d0/0x5bc net/core/gso.c:53 __skb_gso_segment+0x250/0x3cc net/core/gso.c:124 skb_gso_segment include/net/gso.h:83 [inline] validate_xmit_skb+0x3cc/0xe54 net/core/dev.c:3618 validate_xmit_skb_list net/core/dev.c:3668 [inline] __dev_direct_xmit+0x164/0x874 net/core/dev.c:4247 dev_direct_xmit include/linux/netdevice.h:3101 [inline] packet_xmit+0x1a4/0x318 net/packet/af_packet.c:285 packet_snd net/packet/af_packet.c:3085 [inline] packet_sendmsg+0x376c/0x4c98 net/packet/af_packet.c:3117 sock_sendmsg_nosec net/socket.c:725 [inline] sock_sendmsg net/socket.c:748 [inline] __sys_sendto+0x3bc/0x540 net/socket.c:2134 __do_sys_sendto net/socket.c:2146 [inline] __se_sys_sendto net/socket.c:2142 [inline] __arm64_sys_sendto+0xd8/0xf8 net/socket.c:2142 __invoke_syscall arch/arm64/kernel/syscall.c:37 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:51 el0_svc_common+0x130/0x23c arch/arm64/kernel/syscall.c:136 do_el0_svc+0x48/0x58 arch/arm64/kernel/syscall.c:155 el0_svc+0x58/0x16c arch/arm64/kernel/entry-common.c:678 el0t_64_sync_handler+0x84/0xfc arch/arm64/kernel/entry-common.c:696 el0t_64_sync+0x190/0x194 arch/arm64/kernel/entry.S:591 Last potentially related work creation: kasan_save_stack+0x40/0x6c mm/kasan/common.c:45 __kasan_record_aux_stack+0xcc/0xe8 mm/kasan/generic.c:492 kasan_record_aux_stack_noalloc+0x14/0x20 mm/kasan/generic.c:502 __call_rcu_common kernel/rcu/tree.c:2649 [inline] call_rcu+0x104/0xaf4 kernel/rcu/tree.c:2763 netlink_release+0x12c0/0x1818 net/netlink/af_netlink.c:828 __sock_release net/socket.c:654 [inline] sock_close+0xb8/0x1fc net/socket.c:1386 __fput+0x324/0x824 fs/file_table.c:384 ____fput+0x20/0x30 fs/file_table.c:412 task_work_run+0x230/0x2e0 kernel/task_work.c:179 exit_task_work include/linux/task_work.h:38 [inline] do_exit+0x63c/0x1f58 kernel/exit.c:874 do_group_exit+0x194/0x22c kernel/exit.c:1024 get_signal+0x14b0/0x159c kernel/signal.c:2881 do_signal arch/arm64/kernel/signal.c:1249 [inline] do_notify_resume+0x3cc/0x3c90 arch/arm64/kernel/signal.c:1302 exit_to_user_mode_prepare arch/arm64/kernel/entry-common.c:137 [inline] exit_to_user_mode arch/arm64/kernel/entry-common.c:144 [inline] asm_exit_to_user_mode+0x68/0x7c arch/arm64/kernel/entry-common.c:151 ret_from_fork+0x1c/0x20 arch/arm64/kernel/entry.S:856 Second to last potentially related work creation: kasan_save_stack+0x40/0x6c mm/kasan/common.c:45 __kasan_record_aux_stack+0xcc/0xe8 mm/kasan/generic.c:492 kasan_record_aux_stack_noalloc+0x14/0x20 mm/kasan/generic.c:502 __call_rcu_common kernel/rcu/tree.c:2649 [inline] call_rcu+0x104/0xaf4 kernel/rcu/tree.c:2763 netlink_release+0x12c0/0x1818 net/netlink/af_netlink.c:828 __sock_release net/socket.c:654 [inline] sock_close+0xb8/0x1fc net/socket.c:1386 __fput+0x324/0x824 fs/file_table.c:384 ____fput+0x20/0x30 fs/file_table.c:412 task_work_run+0x230/0x2e0 kernel/task_work.c:179 exit_task_work include/linux/task_work.h:38 [inline] do_exit+0x63c/0x1f58 kernel/exit.c:874 do_group_exit+0x194/0x22c kernel/exit.c:1024 __do_sys_exit_group kernel/exit.c:1035 [inline] __se_sys_exit_group kernel/exit.c:1033 [inline] __wake_up_parent+0x0/0x60 kernel/exit.c:1033 __invoke_syscall arch/arm64/kernel/syscall.c:37 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:51 el0_svc_common+0x130/0x23c arch/arm64/kernel/syscall.c:136 do_el0_svc+0x48/0x58 arch/arm64/kernel/syscall.c:155 el0_svc+0x58/0x16c arch/arm64/kernel/entry-common.c:678 el0t_64_sync_handler+0x84/0xfc arch/arm64/kernel/entry-common.c:696 el0t_64_sync+0x190/0x194 arch/arm64/kernel/entry.S:591 The buggy address belongs to the object at ffff0000ceecc000 which belongs to the cache kmalloc-2k of size 2048 The buggy address is located 1264 bytes inside of allocated 2048-byte region [ffff0000ceecc000, ffff0000ceecc800) The buggy address belongs to the physical page: page:000000003698bb75 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x10eec8 head:000000003698bb75 order:3 entire_mapcount:0 nr_pages_mapped:0 pincount:0 anon flags: 0x5ffc00000010200(slab|head|node=0|zone=2|lastcpupid=0x7ff) page_type: 0xffffffff() raw: 05ffc00000010200 ffff0000c0002000 0000000000000000 dead000000000001 raw: 0000000000000000 0000000000080008 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff0000ceecc700: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff0000ceecc780: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff0000ceecc800: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff0000ceecc880: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff0000ceecc900: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ================================================================== ================================================================================ UBSAN: shift-out-of-bounds in arch/arm64/lib/csum.c:116:15 shift exponent 10176 is too large for 64-bit type 'u64' (aka 'unsigned long long') CPU: 0 PID: 15275 Comm: syz-executor.2 Tainted: G B 6.5.0-rc7-syzkaller-g35e2132122ba #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023 Call trace: dump_backtrace+0x1b8/0x1e4 arch/arm64/kernel/stacktrace.c:233 show_stack+0x2c/0x44 arch/arm64/kernel/stacktrace.c:240 __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xd0/0x124 lib/dump_stack.c:106 dump_stack+0x1c/0x28 lib/dump_stack.c:113 ubsan_epilogue lib/ubsan.c:217 [inline] __ubsan_handle_shift_out_of_bounds+0x2f4/0x36c lib/ubsan.c:387 do_csum+0x238/0x254 arch/arm64/lib/csum.c:116 csum_partial+0x30/0x58 lib/checksum.c:128 gso_make_checksum include/net/gso.h:74 [inline] __udp_gso_segment+0xba4/0x1c98 net/ipv4/udp_offload.c:340 udp6_ufo_fragment+0x4dc/0xc48 net/ipv6/udp_offload.c:47 ipv6_gso_segment+0x5cc/0x1760 net/ipv6/ip6_offload.c:120 skb_mac_gso_segment+0x2d0/0x5bc net/core/gso.c:53 __skb_gso_segment+0x250/0x3cc net/core/gso.c:124 skb_gso_segment include/net/gso.h:83 [inline] validate_xmit_skb+0x3cc/0xe54 net/core/dev.c:3618 validate_xmit_skb_list net/core/dev.c:3668 [inline] __dev_direct_xmit+0x164/0x874 net/core/dev.c:4247 dev_direct_xmit include/linux/netdevice.h:3101 [inline] packet_xmit+0x1a4/0x318 net/packet/af_packet.c:285 packet_snd net/packet/af_packet.c:3085 [inline] packet_sendmsg+0x376c/0x4c98 net/packet/af_packet.c:3117 sock_sendmsg_nosec net/socket.c:725 [inline] sock_sendmsg net/socket.c:748 [inline] __sys_sendto+0x3bc/0x540 net/socket.c:2134 __do_sys_sendto net/socket.c:2146 [inline] __se_sys_sendto net/socket.c:2142 [inline] __arm64_sys_sendto+0xd8/0xf8 net/socket.c:2142 __invoke_syscall arch/arm64/kernel/syscall.c:37 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:51 el0_svc_common+0x130/0x23c arch/arm64/kernel/syscall.c:136 do_el0_svc+0x48/0x58 arch/arm64/kernel/syscall.c:155 el0_svc+0x58/0x16c arch/arm64/kernel/entry-common.c:678 el0t_64_sync_handler+0x84/0xfc arch/arm64/kernel/entry-common.c:696 el0t_64_sync+0x190/0x194 arch/arm64/kernel/entry.S:591 ================================================================================ ================================================================================ UBSAN: shift-out-of-bounds in arch/arm64/lib/csum.c:116:25 shift exponent 10176 is too large for 64-bit type 'u64' (aka 'unsigned long long') CPU: 0 PID: 15275 Comm: syz-executor.2 Tainted: G B 6.5.0-rc7-syzkaller-g35e2132122ba #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023 Call trace: dump_backtrace+0x1b8/0x1e4 arch/arm64/kernel/stacktrace.c:233 show_stack+0x2c/0x44 arch/arm64/kernel/stacktrace.c:240 __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xd0/0x124 lib/dump_stack.c:106 dump_stack+0x1c/0x28 lib/dump_stack.c:113 ubsan_epilogue lib/ubsan.c:217 [inline] __ubsan_handle_shift_out_of_bounds+0x2f4/0x36c lib/ubsan.c:387 do_csum+0x250/0x254 arch/arm64/lib/csum.c:116 csum_partial+0x30/0x58 lib/checksum.c:128 gso_make_checksum include/net/gso.h:74 [inline] __udp_gso_segment+0xba4/0x1c98 net/ipv4/udp_offload.c:340 udp6_ufo_fragment+0x4dc/0xc48 net/ipv6/udp_offload.c:47 ipv6_gso_segment+0x5cc/0x1760 net/ipv6/ip6_offload.c:120 skb_mac_gso_segment+0x2d0/0x5bc net/core/gso.c:53 __skb_gso_segment+0x250/0x3cc net/core/gso.c:124 skb_gso_segment include/net/gso.h:83 [inline] validate_xmit_skb+0x3cc/0xe54 net/core/dev.c:3618 validate_xmit_skb_list net/core/dev.c:3668 [inline] __dev_direct_xmit+0x164/0x874 net/core/dev.c:4247 dev_direct_xmit include/linux/netdevice.h:3101 [inline] packet_xmit+0x1a4/0x318 net/packet/af_packet.c:285 packet_snd net/packet/af_packet.c:3085 [inline] packet_sendmsg+0x376c/0x4c98 net/packet/af_packet.c:3117 sock_sendmsg_nosec net/socket.c:725 [inline] sock_sendmsg net/socket.c:748 [inline] __sys_sendto+0x3bc/0x540 net/socket.c:2134 __do_sys_sendto net/socket.c:2146 [inline] __se_sys_sendto net/socket.c:2142 [inline] __arm64_sys_sendto+0xd8/0xf8 net/socket.c:2142 __invoke_syscall arch/arm64/kernel/syscall.c:37 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:51 el0_svc_common+0x130/0x23c arch/arm64/kernel/syscall.c:136 do_el0_svc+0x48/0x58 arch/arm64/kernel/syscall.c:155 el0_svc+0x58/0x16c arch/arm64/kernel/entry-common.c:678 el0t_64_sync_handler+0x84/0xfc arch/arm64/kernel/entry-common.c:696 el0t_64_sync+0x190/0x194 arch/arm64/kernel/entry.S:591 ================================================================================ skb len=9070 headroom=178 headlen=1094 tailroom=0 mac=(178,14) net=(192,1072) trans=1264 shinfo(txflags=0 nr_frags=3 gso(size=5 type=131074 segs=0)) csum(0x0 ip_summed=0 complete_sw=0 valid=0 level=0) hash(0x0 sw=0 l4=0) proto=0x86dd pkttype=0 iif=0 dev name=erspan0 feat=0x0000000000006869 sk family=17 type=3 proto=0 skb linear: 00000000: 0c 2c ff f5 7b 01 6d 27 63 bd 56 37 86 dd 39 8d skb linear: 00000010: 53 75 03 e5 2b 02 59 1f 11 1e e6 16 d5 c0 18 43 skb linear: 00000020: 74 a7 ff e4 ec 55 e0 65 47 86 a7 01 00 93 5b a5 skb linear: 00000030: 14 d4 08 08 ef a0 11 80 16 01 84 2f d0 8d 49 a4 skb linear: 00000040: 7e ff 71 bc 41 31 fe 4c 1f 99 bf 00 a9 00 00 00 skb linear: 00000050: 08 d1 84 3e 77 0a fd 6e 9e f5 83 7d bd 00 00 00 skb linear: 00000060: 00 53 00 00 00 00 00 00 00 00 00 00 00 00 00 00 skb linear: 00000070: 00 00 00 00 00 00 11 00 00 00 05 00 00 00 01 00 skb linear: 00000080: 00 06 89 7b 42 8e 75 eb 00 00 00 00 00 00 00 00 skb linear: 00000090: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 skb linear: 000000a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 skb linear: 000000b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 skb linear: 000000c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 skb linear: 000000d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 skb linear: 000000e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 skb linear: 000000f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 skb linear: 00000100: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 skb linear: 00000110: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 skb linear: 00000120: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ------------[ cut here ]------------ erspan0: caps=(0x0000000000006869, 0x0000000000000000) WARNING: CPU: 0 PID: 15275 at net/core/dev.c:3257 skb_warn_bad_offload+0x160/0x194 net/core/dev.c:3255 Modules linked in: CPU: 0 PID: 15275 Comm: syz-executor.2 Tainted: G B 6.5.0-rc7-syzkaller-g35e2132122ba #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023 pstate: 60400005 (nZCv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--) pc : skb_warn_bad_offload+0x160/0x194 net/core/dev.c:3255 lr : skb_warn_bad_offload+0x160/0x194 net/core/dev.c:3255 sp : ffff800099037550 x29: ffff800099037550 x28: dfff800000000000 x27: ffff000124140000 x26: 0000000000000020 x25: 1fffe0001adf51c8 x24: ffff80008c894b80 x23: dfff800000000000 x22: ffff0000d6fa8dd8 x21: ffff000124140000 x20: ffff000124140000 x19: ffff0001241400f0 x18: 1fffe0003683adc6 x17: ffff80008e09d000 x16: ffff80008a571864 x15: 0000000000000001 x14: 1fffe0003683d530 x13: 0000000000000000 x12: 0000000000000000 x11: 0000000000000001 x10: 0000000000000000 x9 : a63f20c19becc300 x8 : a63f20c19becc300 x7 : 1fffe0003683adc7 x6 : ffff800080292a1c x5 : 0000000000000000 x4 : 0000000000000001 x3 : 0000000000000000 x2 : ffff0000c4af9bc0 x1 : 0000000000000000 x0 : ffff800080292abc Call trace: skb_warn_bad_offload+0x160/0x194 net/core/dev.c:3255 __skb_gso_segment+0x2f4/0x3cc net/core/gso.c:127 skb_gso_segment include/net/gso.h:83 [inline] validate_xmit_skb+0x3cc/0xe54 net/core/dev.c:3618 validate_xmit_skb_list net/core/dev.c:3668 [inline] __dev_direct_xmit+0x164/0x874 net/core/dev.c:4247 dev_direct_xmit include/linux/netdevice.h:3101 [inline] packet_xmit+0x1a4/0x318 net/packet/af_packet.c:285 packet_snd net/packet/af_packet.c:3085 [inline] packet_sendmsg+0x376c/0x4c98 net/packet/af_packet.c:3117 sock_sendmsg_nosec net/socket.c:725 [inline] sock_sendmsg net/socket.c:748 [inline] __sys_sendto+0x3bc/0x540 net/socket.c:2134 __do_sys_sendto net/socket.c:2146 [inline] __se_sys_sendto net/socket.c:2142 [inline] __arm64_sys_sendto+0xd8/0xf8 net/socket.c:2142 __invoke_syscall arch/arm64/kernel/syscall.c:37 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:51 el0_svc_common+0x130/0x23c arch/arm64/kernel/syscall.c:136 do_el0_svc+0x48/0x58 arch/arm64/kernel/syscall.c:155 el0_svc+0x58/0x16c arch/arm64/kernel/entry-common.c:678 el0t_64_sync_handler+0x84/0xfc arch/arm64/kernel/entry-common.c:696 el0t_64_sync+0x190/0x194 arch/arm64/kernel/entry.S:591 irq event stamp: 3437 hardirqs last enabled at (3437): [] raw_spin_rq_unlock_irq kernel/sched/sched.h:1378 [inline] hardirqs last enabled at (3437): [] finish_lock_switch+0xbc/0x1e4 kernel/sched/core.c:5133 hardirqs last disabled at (3436): [] __schedule+0x2b4/0x23b4 kernel/sched/core.c:6609 softirqs last enabled at (3020): [] softirq_handle_end kernel/softirq.c:399 [inline] softirqs last enabled at (3020): [] __do_softirq+0xac0/0xd54 kernel/softirq.c:582 softirqs last disabled at (3009): [] ____do_softirq+0x14/0x20 arch/arm64/kernel/irq.c:80 ---[ end trace 0000000000000000 ]---