syzbot


KASAN: alloca-out-of-bounds Read in update_stack_state (2)

Status: closed as invalid on 2018/05/13 12:37
Subsystems: net
[Documentation on labels]
First crash: 2481d, last: 2481d

Sample crash report:
8021q: adding VLAN 0 to HW filter on device team0
8021q: adding VLAN 0 to HW filter on device team0
8021q: adding VLAN 0 to HW filter on device team0
8021q: adding VLAN 0 to HW filter on device team0
==================================================================
BUG: KASAN: alloca-out-of-bounds in __read_once_size include/linux/compiler.h:188 [inline]
BUG: KASAN: alloca-out-of-bounds in update_stack_state+0x5d9/0x670 arch/x86/kernel/unwind_frame.c:270
Read of size 8 at addr ffff8801c9137178 by task ip/6252

CPU: 1 PID: 6252 Comm: ip Not tainted 4.16.0+ #2
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 <IRQ>
 __dump_stack lib/dump_stack.c:77 [inline]
 dump_stack+0x1b9/0x294 lib/dump_stack.c:113
 print_address_description+0x6c/0x20b mm/kasan/report.c:256
 kasan_report_error mm/kasan/report.c:354 [inline]
 kasan_report.cold.7+0xac/0x2f5 mm/kasan/report.c:412
 __asan_report_load8_noabort+0x14/0x20 mm/kasan/report.c:433
 __read_once_size include/linux/compiler.h:188 [inline]
 update_stack_state+0x5d9/0x670 arch/x86/kernel/unwind_frame.c:270
 unwind_next_frame.part.7+0x1a9/0x9c0 arch/x86/kernel/unwind_frame.c:329
 unwind_next_frame+0x3e/0x50 arch/x86/kernel/unwind_frame.c:287
 __save_stack_trace+0x6e/0xd0 arch/x86/kernel/stacktrace.c:44
 save_stack_trace+0x1a/0x20 arch/x86/kernel/stacktrace.c:60
 save_stack+0x43/0xd0 mm/kasan/kasan.c:448
 set_track mm/kasan/kasan.c:460 [inline]
 kasan_kmalloc+0xc4/0xe0 mm/kasan/kasan.c:553
 kasan_slab_alloc+0x12/0x20 mm/kasan/kasan.c:490
 slab_post_alloc_hook mm/slab.h:444 [inline]
 slab_alloc_node mm/slab.c:3335 [inline]
 kmem_cache_alloc_node+0x131/0x780 mm/slab.c:3642
 __alloc_skb+0x111/0x780 net/core/skbuff.c:193
 alloc_skb include/linux/skbuff.h:987 [inline]
 alloc_skb_with_frags+0x137/0x760 net/core/skbuff.c:5249
 sock_alloc_send_pskb+0x87a/0xae0 net/core/sock.c:2088
 sock_alloc_send_skb+0x32/0x40 net/core/sock.c:2105
 mld_newpack+0x382/0xac0 net/ipv6/mcast.c:1585
 add_grhead.isra.28+0x29b/0x370 net/ipv6/mcast.c:1689
 add_grec+0xf35/0x1200 net/ipv6/mcast.c:1820
 mld_send_initial_cr.part.29+0xca/0x160 net/ipv6/mcast.c:2070
 mld_send_initial_cr net/ipv6/mcast.c:2059 [inline]
 mld_dad_timer_expire+0x3e/0x130 net/ipv6/mcast.c:2093
 call_timer_fn+0x230/0x940 kernel/time/timer.c:1326
 expire_timers kernel/time/timer.c:1363 [inline]
 __run_timers+0x79e/0xc50 kernel/time/timer.c:1666
 run_timer_softirq+0x4c/0x70 kernel/time/timer.c:1692
 __do_softirq+0x2e0/0xaf5 kernel/softirq.c:285
 invoke_softirq kernel/softirq.c:365 [inline]
 irq_exit+0x1d1/0x200 kernel/softirq.c:405
 exiting_irq arch/x86/include/asm/apic.h:525 [inline]
 smp_apic_timer_interrupt+0x17e/0x710 arch/x86/kernel/apic/apic.c:1052
 apic_timer_interrupt+0xf/0x20 arch/x86/entry/entry_64.S:862
 </IRQ>
RIP: 0010:kasan_unpoison_shadow+0x14/0x50 mm/kasan/kasan.c:68
RSP: 0018:ffff8801c91371a0 EFLAGS: 00000a06 ORIG_RAX: ffffffffffffff13
RAX: 1ffff10039226e39 RBX: 0000000000000000 RCX: 0000000000000000
RDX: 0000000000000000 RSI: 0000000000000068 RDI: 1ffff10039226e2c
RBP: ffff8801c91371a8 R08: ffff8801ca38e3c0 R09: 0000000000000000
R10: ffff8801ca38e3c0 R11: 0000000000000000 R12: ffff8801c91375d0
R13: 0000000000000005 R14: 0000000000000000 R15: 0000000000000000
 __asan_allocas_unpoison+0x16/0x20 mm/kasan/kasan.c:775
 put_net include/net/net_namespace.h:225 [inline]
 rtnl_newlink+0x1094/0x1a40 net/core/rtnetlink.c:3070
 rtnetlink_rcv_msg+0x466/0xc10 net/core/rtnetlink.c:4646
 netlink_rcv_skb+0x172/0x440 net/netlink/af_netlink.c:2448
 rtnetlink_rcv+0x1c/0x20 net/core/rtnetlink.c:4664
 netlink_unicast_kernel net/netlink/af_netlink.c:1310 [inline]
 netlink_unicast+0x58b/0x740 net/netlink/af_netlink.c:1336
 netlink_sendmsg+0x9f0/0xfa0 net/netlink/af_netlink.c:1901
 sock_sendmsg_nosec net/socket.c:629 [inline]
 sock_sendmsg+0xd5/0x120 net/socket.c:639
 ___sys_sendmsg+0x805/0x940 net/socket.c:2117
 __sys_sendmsg+0x115/0x270 net/socket.c:2155
 SYSC_sendmsg net/socket.c:2164 [inline]
 SyS_sendmsg+0x29/0x30 net/socket.c:2162
 do_syscall_64+0x29e/0x9d0 arch/x86/entry/common.c:287
 entry_SYSCALL_64_after_hwframe+0x42/0xb7
RIP: 0033:0x7f56a1733320
RSP: 002b:00007ffd35931628 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
RAX: ffffffffffffffda RBX: 00007ffd35935720 RCX: 00007f56a1733320
RDX: 0000000000000000 RSI: 00007ffd35931660 RDI: 0000000000000013
RBP: 00007ffd35931660 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 000000005ad0b0e5
R13: 0000000000000000 R14: 00000000006395c0 R15: 00007ffd35935ef8

The buggy address belongs to the page:
page:ffffea0007244dc0 count:0 mapcount:0 mapping:0000000000000000 index:0x0
flags: 0x2fffc0000000000()
raw: 02fffc0000000000 0000000000000000 0000000000000000 00000000ffffffff
raw: 0000000000000000 ffffea0007240101 0000000000000000 0000000000000000
page dumped because: kasan: bad access detected

Memory state around the buggy address:
 ffff8801c9137000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
 ffff8801c9137080: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>ffff8801c9137100: 00 00 00 00 00 00 00 00 00 00 00 00 ca ca ca ca
                                                                ^
 ffff8801c9137180: 00 cb cb cb cb cb cb cb 00 00 00 00 00 00 00 00
 ffff8801c9137200: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 f1 f1
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2018/04/13 13:30 upstream 16e205cf42da 0a0c5db6 .config console log report ci-upstream-kasan-gce
* Struck through repros no longer work on HEAD.