syzbot


UBSAN: shift-out-of-bounds in befs_check_sb

Status: upstream: reported C repro on 2023/08/05 00:55
Bug presence: origin:upstream
[Documentation on labels]
Reported-by: syzbot+eff469f255ca9e0c47f5@syzkaller.appspotmail.com
First crash: 324d, last: 157d
Fix bisection: failed (error log, bisect log)
  
Bug presence (1)
Date Name Commit Repro Result
2023/12/29 upstream (ToT) f016f7547aee C [report] UBSAN: shift-out-of-bounds in befs_check_sb
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-5.15 UBSAN: shift-out-of-bounds in befs_check_sb origin:upstream C error 8 153d 332d 0/3 upstream: reported C repro on 2023/07/28 00:42
upstream UBSAN: shift-out-of-bounds in befs_check_sb fs C error done 36 11d 348d 0/27 upstream: reported C repro on 2023/07/12 13:47

Sample crash report:
loop0: detected capacity change from 0 to 128
================================================================================
UBSAN: shift-out-of-bounds in fs/befs/super.c:96:9
shift exponent 3229888891 is too large for 32-bit type 'int'
CPU: 1 PID: 3542 Comm: syz-executor295 Not tainted 6.1.69-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 11/17/2023
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1e3/0x2cb lib/dump_stack.c:106
 ubsan_epilogue lib/ubsan.c:151 [inline]
 __ubsan_handle_shift_out_of_bounds+0x3bf/0x420 lib/ubsan.c:321
 befs_check_sb+0x471/0x4a0 fs/befs/super.c:96
 befs_fill_super+0x9ea/0xfb0 fs/befs/linuxvfs.c:873
 mount_bdev+0x2c9/0x3f0 fs/super.c:1432
 legacy_get_tree+0xeb/0x180 fs/fs_context.c:632
 vfs_get_tree+0x88/0x270 fs/super.c:1562
 do_new_mount+0x28b/0xae0 fs/namespace.c:3040
 do_mount fs/namespace.c:3383 [inline]
 __do_sys_mount fs/namespace.c:3591 [inline]
 __se_sys_mount+0x2d5/0x3c0 fs/namespace.c:3568
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:81
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7ff2043278ba
Code: d8 64 89 02 48 c7 c0 ff ff ff ff eb a6 e8 5e 04 00 00 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffd288b0988 EFLAGS: 00000282 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 00007ffd288b0990 RCX: 00007ff2043278ba
RDX: 0000000020000100 RSI: 0000000020009e40 RDI: 00007ffd288b0990
RBP: 0000000000000004 R08: 00007ffd288b09d0 R09: 0000000000009e1f
R10: 0000000003008001 R11: 0000000000000282 R12: 00007ffd288b09d0
R13: 0000000000000003 R14: 0000000000010000 R15: 0000000000000001
 </TASK>
================================================================================

Crashes (5):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/12/29 21:03 linux-6.1.y 4aa6747d9352 fb427a07 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan UBSAN: shift-out-of-bounds in befs_check_sb
2023/08/05 00:53 linux-6.1.y 52a953d0934b cdae481e .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan-arm64 UBSAN: shift-out-of-bounds in befs_check_sb
2024/01/19 11:42 linux-6.1.y fec3b1451d5f 21772ce4 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan UBSAN: shift-out-of-bounds in befs_check_sb
2024/01/19 16:42 linux-6.1.y fec3b1451d5f 9bd8dcda .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 UBSAN: shift-out-of-bounds in befs_check_sb
2024/01/19 04:43 linux-6.1.y fec3b1451d5f 21772ce4 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 UBSAN: shift-out-of-bounds in befs_check_sb
* Struck through repros no longer work on HEAD.