syzbot


BUG: unable to handle kernel paging request in crypto_shash_update

Status: upstream: reported C repro on 2024/07/16 01:23
Subsystems: bcachefs
[Documentation on labels]
Reported-by: syzbot+e46f29a4b409be681ad9@syzkaller.appspotmail.com
First crash: 130d, last: 7d19h
Discussions (2)
Title Replies (including bot) Last reply
[syzbot] Monthly crypto report (Nov 2024) 1 (2) 2024/11/14 11:25
[syzbot] [crypto?] [bcachefs?] BUG: unable to handle kernel paging request in crypto_shash_update 0 (1) 2024/07/16 01:23
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-5.15 KASAN: slab-out-of-bounds Read in crypto_shash_update 6 138d 148d 0/3 auto-obsoleted due to no activity on 2024/10/13 17:32
linux-6.1 KASAN: slab-out-of-bounds Read in crypto_shash_update 2 138d 138d 0/3 auto-obsoleted due to no activity on 2024/10/14 02:06
Last patch testing requests (2)
Created Duration User Patch Repo Result
2024/10/19 13:03 18m retest repro git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci report log
2024/08/10 12:16 33m retest repro git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci report log

Sample crash report:
 __invoke_syscall arch/arm64/kernel/syscall.c:34 [inline]
 invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:48
 el0_svc_common+0x130/0x23c arch/arm64/kernel/syscall.c:131
 do_el0_svc+0x48/0x58 arch/arm64/kernel/syscall.c:150
 el0_svc+0x54/0x168 arch/arm64/kernel/entry-common.c:712
 el0t_64_sync_handler+0x84/0xfc arch/arm64/kernel/entry-common.c:730
 el0t_64_sync+0x190/0x194 arch/arm64/kernel/entry.S:598
Unable to handle kernel paging request at virtual address dfff800000000004
KASAN: null-ptr-deref in range [0x0000000000000020-0x0000000000000027]
Mem abort info:
  ESR = 0x0000000096000005
  EC = 0x25: DABT (current EL), IL = 32 bits
  SET = 0, FnV = 0
  EA = 0, S1PTW = 0
  FSC = 0x05: level 1 translation fault
Data abort info:
  ISV = 0, ISS = 0x00000005, ISS2 = 0x00000000
  CM = 0, WnR = 0, TnD = 0, TagAccess = 0
  GCS = 0, Overlay = 0, DirtyBit = 0, Xs = 0
[dfff800000000004] address between user and kernel address ranges
Internal error: Oops: 0000000096000005 [#1] PREEMPT SMP
Modules linked in:
CPU: 1 PID: 6452 Comm: syz-executor232 Not tainted 6.10.0-rc7-syzkaller-gc912bf709078 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/07/2024
pstate: 80400005 (Nzcv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
pc : crypto_shash_alg include/crypto/hash.h:733 [inline]
pc : crypto_shash_update+0x50/0xa8 crypto/shash.c:52
lr : crypto_shash_update+0x30/0xa8 crypto/shash.c:51
sp : ffff80009ff56620
x29: ffff80009ff56620 x28: fff1000040000000 x27: ffff80009ff56800
x26: ffff0000e1c404d0 x25: dfff800000000000 x24: ffff80009ff56800
x23: dfff800000000000 x22: 0000000000000020 x21: ffff80009ff56800
x20: ffff0000c6009000 x19: 0000000000001000 x18: 0000000000000008
x17: 0000000000000000 x16: ffff800082f8f174 x15: 0000000000000001
x14: 1ffff00011e7a636 x13: 0000000000000000 x12: 0000000000000000
x11: ffff700011e7a637 x10: 0000000000ff0100 x9 : 0000000000000000
x8 : 0000000000000004 x7 : 0000000000000001 x6 : 0000000000000001
x5 : 00000000ffffffff x4 : 0000000000000cc0 x3 : 0000000000000040
x2 : 0000000000001000 x1 : ffff0000c6009000 x0 : ffff80009ff56800
Call trace:
 crypto_shash_alg include/crypto/hash.h:733 [inline]
 crypto_shash_update+0x50/0xa8 crypto/shash.c:52
 __bch2_checksum_bio+0xbf4/0x10d8 fs/bcachefs/checksum.c:300
 bch2_checksum_bio+0xc0/0x10c fs/bcachefs/checksum.c:319
 bch2_write_extent fs/bcachefs/io_write.c:1044 [inline]
 __bch2_write+0x1d20/0x47f4 fs/bcachefs/io_write.c:1461
 bch2_write+0x8bc/0x153c fs/bcachefs/io_write.c:1634
 closure_queue include/linux/closure.h:269 [inline]
 closure_call include/linux/closure.h:425 [inline]
 bch2_dio_write_loop fs/bcachefs/fs-io-direct.c:531 [inline]
 bch2_direct_write+0x1670/0x2988 fs/bcachefs/fs-io-direct.c:654
 bch2_write_iter+0x1a8/0x2d24 fs/bcachefs/fs-io-buffered.c:1135
 new_sync_write fs/read_write.c:497 [inline]
 vfs_write+0x8f8/0xc38 fs/read_write.c:590
 ksys_write+0x15c/0x26c fs/read_write.c:643
 __do_sys_write fs/read_write.c:655 [inline]
 __se_sys_write fs/read_write.c:652 [inline]
 __arm64_sys_write+0x7c/0x90 fs/read_write.c:652
 __invoke_syscall arch/arm64/kernel/syscall.c:34 [inline]
 invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:48
 el0_svc_common+0x130/0x23c arch/arm64/kernel/syscall.c:131
 do_el0_svc+0x48/0x58 arch/arm64/kernel/syscall.c:150
 el0_svc+0x54/0x168 arch/arm64/kernel/entry-common.c:712
 el0t_64_sync_handler+0x84/0xfc arch/arm64/kernel/entry-common.c:730
 el0t_64_sync+0x190/0x194 arch/arm64/kernel/entry.S:598
Code: 9778c38d f94002a8 91008116 d343fec8 (38776908) 
---[ end trace 0000000000000000 ]---
----------------
Code disassembly (best guess):
   0:	9778c38d 	bl	0xfffffffffde30e34
   4:	f94002a8 	ldr	x8, [x21]
   8:	91008116 	add	x22, x8, #0x20
   c:	d343fec8 	lsr	x8, x22, #3
* 10:	38776908 	ldrb	w8, [x8, x23] <-- trapping instruction

Crashes (6):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/07/13 23:53 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci c912bf709078 eaeb5c15 .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-gce-arm64 BUG: unable to handle kernel paging request in crypto_shash_update
2024/11/13 11:13 upstream 3022e9d00ebe 62026c85 .config console log report syz / log [disk image (non-bootable)] [vmlinux] [kernel image] [mounted in repro] ci-snapshot-upstream-root BUG: unable to handle kernel paging request in crypto_shash_update
2024/11/13 09:39 upstream 3022e9d00ebe 62026c85 .config console log report [disk image (non-bootable)] [vmlinux] [kernel image] ci-snapshot-upstream-root BUG: unable to handle kernel paging request in crypto_shash_update
2024/07/27 12:06 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci c912bf709078 46eb10b7 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-gce-arm64 BUG: unable to handle kernel paging request in crypto_shash_update
2024/07/13 22:46 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci c912bf709078 eaeb5c15 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-gce-arm64 BUG: unable to handle kernel paging request in crypto_shash_update
2024/07/14 11:26 upstream 4d145e3f830b eaeb5c15 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs general protection fault in crypto_shash_update
* Struck through repros no longer work on HEAD.