syzbot


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

Status: closed as invalid on 2018/04/13 13:01
Subsystems: kernel
[Documentation on labels]
First crash: 2482d, last: 2482d
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KASAN: alloca-out-of-bounds Read in tick_sched_handle kernel C 1144 2482d 2490d 0/28 closed as invalid on 2018/04/13 11:18
upstream KASAN: alloca-out-of-bounds Read in tick_sched_handle (3) kernel syz 68 2482d 2482d 0/28 closed as invalid on 2018/05/13 12:27

Sample crash report:
netlink: 'syz-executor5': attribute type 1 has an invalid length.
netlink: 'syz-executor1': attribute type 1 has an invalid length.
netlink: 'syz-executor4': attribute type 1 has an invalid length.
netlink: 'syz-executor7': attribute type 1 has an invalid length.
==================================================================
BUG: KASAN: alloca-out-of-bounds in tick_sched_handle+0x16c/0x180 kernel/time/tick-sched.c:173
Read of size 8 at addr ffff8801acc4f2f0 by task syz-executor3/5709

CPU: 1 PID: 5709 Comm: syz-executor3 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
 tick_sched_handle+0x16c/0x180 kernel/time/tick-sched.c:173
 tick_sched_timer+0x45/0x130 kernel/time/tick-sched.c:1283
 __run_hrtimer kernel/time/hrtimer.c:1386 [inline]
 __hrtimer_run_queues+0x3e3/0x10a0 kernel/time/hrtimer.c:1448
 hrtimer_interrupt+0x286/0x650 kernel/time/hrtimer.c:1506
 local_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1025 [inline]
 smp_apic_timer_interrupt+0x15d/0x710 arch/x86/kernel/apic/apic.c:1050
 apic_timer_interrupt+0xf/0x20 arch/x86/entry/entry_64.S:862
 </IRQ>
RIP: 0010:rcu_lock_release include/linux/rcupdate.h:251 [inline]
RIP: 0010:rcu_read_unlock include/linux/rcupdate.h:688 [inline]
RIP: 0010:nfnetlink_rcv_msg+0x6a0/0xfe0 net/netfilter/nfnetlink.c:196
RSP: 0018:ffff8801acc4f310 EFLAGS: 00000293 ORIG_RAX: ffffffffffffff13
RAX: ffff8801ad6ec300 RBX: ffffffff8606e8d0 RCX: ffffffff85ec17df
RDX: 0000000000000000 RSI: ffffffff85ec18a9 RDI: 0000000000000005
RBP: ffff8801acc4f480 R08: ffff8801ad6ec300 R09: ffffed0036096094
R10: ffffed0036096094 R11: ffff8801b04b04a3 R12: 0000000000000000
R13: 0000000000000003 R14: 0000000000000000 R15: ffff8801ad55f780
 netlink_rcv_skb+0x172/0x440 net/netlink/af_netlink.c:2448
 nfnetlink_rcv+0x1fe/0x1ba0 net/netfilter/nfnetlink.c:513
 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:0x455319
RSP: 002b:00007fc264ff0c68 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
RAX: ffffffffffffffda RBX: 00007fc264ff16d4 RCX: 0000000000455319
RDX: 0000000000000000 RSI: 0000000020d65000 RDI: 0000000000000004
RBP: 000000000072bea0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00000000ffffffff
R13: 00000000000004f0 R14: 00000000006fa720 R15: 0000000000000000

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

Memory state around the buggy address:
 ffff8801acc4f180: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
 ffff8801acc4f200: 00 00 00 00 00 00 00 00 00 00 00 00 ca ca ca ca
>ffff8801acc4f280: 00 00 00 00 00 00 00 00 00 00 00 cb cb cb cb cb
                                                             ^
 ffff8801acc4f300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
 ffff8801acc4f380: 00 00 00 00 00 00 00 f1 f1 f1 f1 f8 f2 f2 f2 f2
==================================================================

Crashes (7):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2018/04/13 12:10 upstream 16e205cf42da 0a0c5db6 .config console log report syz ci-upstream-kasan-gce-root
2018/04/13 12:51 upstream 16e205cf42da 0a0c5db6 .config console log report ci-upstream-kasan-gce
2018/04/13 12:00 upstream 16e205cf42da 0a0c5db6 .config console log report ci-upstream-kasan-gce-root
2018/04/13 11:32 upstream 16e205cf42da 0a0c5db6 .config console log report ci-upstream-kasan-gce
2018/04/13 12:05 net-next-old 5d1365940a68 0a0c5db6 .config console log report ci-upstream-net-kasan-gce
2018/04/13 12:02 net-next-old 5d1365940a68 0a0c5db6 .config console log report ci-upstream-net-kasan-gce
2018/04/13 11:49 net-next-old 5d1365940a68 0a0c5db6 .config console log report ci-upstream-net-kasan-gce
* Struck through repros no longer work on HEAD.