syzbot


KASAN: stack-out-of-bounds Read in update_stack_state

Status: auto-closed as invalid on 2020/06/10 22:34
Reported-by: syzbot+59fa3adcbad32e23e1e7@syzkaller.appspotmail.com
First crash: 1772d, last: 1765d
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KASAN: stack-out-of-bounds Read in update_stack_state kernel C unreliable done 388 1791d 2485d 15/28 fixed on 2020/08/18 12:30
linux-4.14 KASAN: stack-out-of-bounds Read in update_stack_state C inconclusive 11 1640d 1933d 0/1 upstream: reported C repro on 2019/08/27 12:47
android-5-10 KASAN: stack-out-of-bounds Read in update_stack_state 1 314d 314d 0/2 auto-obsoleted due to no activity on 2024/05/02 04:08

Sample crash report:
==================================================================
BUG: KASAN: stack-out-of-bounds in user_mode arch/x86/include/asm/ptrace.h:131 [inline]
BUG: KASAN: stack-out-of-bounds in update_stack_state+0x376/0x5b0 arch/x86/kernel/unwind_frame.c:244
Read of size 8 at addr ffff88819d0ffe60 by task syz-executor.0/677

CPU: 1 PID: 677 Comm: syz-executor.0 Not tainted 5.4.18-syzkaller-00147-g0dba8e724663 #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+0x1b0/0x228 lib/dump_stack.c:118
 print_address_description+0x96/0x5d0 mm/kasan/report.c:374
 __kasan_report+0x14b/0x1c0 mm/kasan/report.c:506
 kasan_report+0x26/0x50 mm/kasan/common.c:634
 __asan_report_load8_noabort+0x14/0x20 mm/kasan/generic_report.c:132
 user_mode arch/x86/include/asm/ptrace.h:131 [inline]
 update_stack_state+0x376/0x5b0 arch/x86/kernel/unwind_frame.c:244
 unwind_next_frame+0x415/0x870 arch/x86/kernel/unwind_frame.c:311
 arch_stack_walk+0xb4/0xe0 arch/x86/kernel/stacktrace.c:25
 stack_trace_save_tsk+0x2d5/0x470 kernel/stacktrace.c:151
 proc_pid_stack+0x137/0x200 fs/proc/base.c:455
 proc_single_show+0xd5/0x130 fs/proc/base.c:757
 seq_read+0x4a8/0xdd0 fs/seq_file.c:229
 do_loop_readv_writev fs/read_write.c:717 [inline]
 do_iter_read+0x4a2/0x5b0 fs/read_write.c:938
 vfs_readv fs/read_write.c:1000 [inline]
 do_preadv+0x1f4/0x330 fs/read_write.c:1092
 __do_sys_preadv fs/read_write.c:1142 [inline]
 __se_sys_preadv fs/read_write.c:1137 [inline]
 __x64_sys_preadv+0x9e/0xb0 fs/read_write.c:1137
 do_syscall_64+0xc0/0x100 arch/x86/entry/common.c:290
 entry_SYSCALL_64_after_hwframe+0x44/0xa9
RIP: 0033:0x45b3b9
Code: ad b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 0f 83 7b b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00
RSP: 002b:00007f9c9d29dc78 EFLAGS: 00000246 ORIG_RAX: 0000000000000127
RAX: ffffffffffffffda RBX: 00007f9c9d29e6d4 RCX: 000000000045b3b9
RDX: 000000000000022a RSI: 00000000200017c0 RDI: 0000000000000006
RBP: 000000000075bfc8 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00000000ffffffff
R13: 0000000000000851 R14: 00000000004c9c95 R15: 000000000075bfd4

The buggy address belongs to the page:
page:ffffea0006743fc0 refcount:0 mapcount:0 mapping:0000000000000000 index:0x0
raw: 8000000000000000 0000000000000000 ffffea0006743f88 0000000000000000
raw: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000000
page dumped because: kasan: bad access detected

Memory state around the buggy address:
 ffff88819d0ffd00: f1 f1 f1 f1 00 f2 f2 f2 00 00 f3 f3 00 00 00 00
 ffff88819d0ffd80: 00 00 00 00 00 00 00 00 00 00 00 00 f1 f1 f1 f1
>ffff88819d0ffe00: 00 00 00 00 00 00 00 00 00 f2 f2 f2 f2 f2 00 00
                                                       ^
 ffff88819d0ffe80: f3 f3 f3 f3 00 00 00 00 00 00 00 00 00 00 00 00
 ffff88819d0fff00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
==================================================================

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2020/02/11 22:33 https://android.googlesource.com/kernel/common android-5.4 0dba8e724663 4d1ab643 .config console log report ci2-android-5-4-kasan
2020/02/04 07:19 https://android.googlesource.com/kernel/common android-5.4 b3fbbf580c21 93e5e335 .config console log report ci2-android-5-4-kasan
* Struck through repros no longer work on HEAD.