syzbot


KASAN: slab-out-of-bounds Read in ntfs_fill_super

Status: upstream: reported C repro on 2022/10/01 14:27
Subsystems: ntfs3 (incorrect?)
Reported-by: syzbot+bd6d0c83fe8442ad6ef5@syzkaller.appspotmail.com
First crash: 179d, last: 63d

Cause bisection: failed (error log, bisect log)

Fix bisection: fixed by (bisect log) [merge commit]:
commit 675f176b4dcc2b75adbcea7ba0e9a649527f53bd
Author: David S. Miller <davem@davemloft.net>
Date: Fri Feb 17 11:06:39 2023 +0000

  Merge ra.kernel.org:/pub/scm/linux/kernel/git/netdev/net


Sample crash report:
ntfs3: loop3: RAW NTFS volume: Filesystem size 0.00 Gb > volume size 0.00 Gb. Mount in read-only
general protection fault, probably for non-canonical address 0xdffffc0000000002: 0000 [#1] PREEMPT SMP KASAN
KASAN: null-ptr-deref in range [0x0000000000000010-0x0000000000000017]
CPU: 1 PID: 3641 Comm: syz-executor420 Not tainted 6.0.0-syzkaller-09423-g493ffd6605b2 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/22/2022
RIP: 0010:ntfs_init_from_boot fs/ntfs3/super.c:844 [inline]
RIP: 0010:ntfs_fill_super+0x15b5/0x42a0 fs/ntfs3/super.c:935
Code: 00 00 00 00 00 fc ff df 80 3c 08 00 74 08 48 89 df e8 ff 14 11 ff 4c 89 2b 4c 89 e8 48 c1 e8 03 48 b9 00 00 00 00 00 fc ff df <8a> 04 08 84 c0 0f 85 96 16 00 00 41 c7 45 00 46 49 4c 45 4d 8d 7d
RSP: 0018:ffffc90003fcfae0 EFLAGS: 00010202
RAX: 0000000000000002 RBX: ffff888075460080 RCX: dffffc0000000000
RDX: ffff8880203dd880 RSI: 0000000000000d40 RDI: 0000000000000000
RBP: ffffc90003fcfcb0 R08: ffffffff82c8d6e5 R09: fffffbfff1c19fde
R10: fffffbfff1c19fde R11: 1ffffffff1c19fdd R12: 00000000000001ff
R13: 0000000000000010 R14: ffff888075460320 R15: 0000000000000000
FS:  0000555555f93300(0000) GS:ffff8880b9b00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000555555f932c0 CR3: 0000000075ed4000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 get_tree_bdev+0x400/0x620 fs/super.c:1323
 vfs_get_tree+0x88/0x270 fs/super.c:1530
 do_new_mount+0x289/0xad0 fs/namespace.c:3040
 do_mount fs/namespace.c:3383 [inline]
 __do_sys_mount fs/namespace.c:3591 [inline]
 __se_sys_mount+0x2d3/0x3c0 fs/namespace.c:3568
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7efc95f6311a
Code: 48 c7 c2 c0 ff ff ff f7 d8 64 89 02 b8 ff ff ff ff eb d2 e8 a8 00 00 00 0f 1f 84 00 00 00 00 00 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 c0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffde97f1518 EFLAGS: 00000286 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 0000000000000004 RCX: 00007efc95f6311a
RDX: 0000000020000000 RSI: 0000000020000100 RDI: 00007ffde97f1530
RBP: 00007ffde97f1530 R08: 00007ffde97f1570 R09: 0000555555f932c0
R10: 0000000000000000 R11: 0000000000000286 R12: 0000000000000005
R13: 00007ffde97f1570 R14: 0000000000000037 R15: 0000000020000728
 </TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:ntfs_init_from_boot fs/ntfs3/super.c:844 [inline]
RIP: 0010:ntfs_fill_super+0x15b5/0x42a0 fs/ntfs3/super.c:935
Code: 00 00 00 00 00 fc ff df 80 3c 08 00 74 08 48 89 df e8 ff 14 11 ff 4c 89 2b 4c 89 e8 48 c1 e8 03 48 b9 00 00 00 00 00 fc ff df <8a> 04 08 84 c0 0f 85 96 16 00 00 41 c7 45 00 46 49 4c 45 4d 8d 7d
RSP: 0018:ffffc90003fcfae0 EFLAGS: 00010202
RAX: 0000000000000002 RBX: ffff888075460080 RCX: dffffc0000000000
RDX: ffff8880203dd880 RSI: 0000000000000d40 RDI: 0000000000000000
RBP: ffffc90003fcfcb0 R08: ffffffff82c8d6e5 R09: fffffbfff1c19fde
R10: fffffbfff1c19fde R11: 1ffffffff1c19fdd R12: 00000000000001ff
R13: 0000000000000010 R14: ffff888075460320 R15: 0000000000000000
FS:  0000555555f93300(0000) GS:ffff8880b9b00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007efc95f1e668 CR3: 0000000075ed4000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess), 7 bytes skipped:
   0:	df 80 3c 08 00 74    	filds  0x7400083c(%rax)
   6:	08 48 89             	or     %cl,-0x77(%rax)
   9:	df e8                	fucomip %st(0),%st
   b:	ff 14 11             	callq  *(%rcx,%rdx,1)
   e:	ff 4c 89 2b          	decl   0x2b(%rcx,%rcx,4)
  12:	4c 89 e8             	mov    %r13,%rax
  15:	48 c1 e8 03          	shr    $0x3,%rax
  19:	48 b9 00 00 00 00 00 	movabs $0xdffffc0000000000,%rcx
  20:	fc ff df
* 23:	8a 04 08             	mov    (%rax,%rcx,1),%al <-- trapping instruction
  26:	84 c0                	test   %al,%al
  28:	0f 85 96 16 00 00    	jne    0x16c4
  2e:	41 c7 45 00 46 49 4c 	movl   $0x454c4946,0x0(%r13)
  35:	45
  36:	4d                   	rex.WRB
  37:	8d                   	.byte 0x8d
  38:	7d                   	.byte 0x7d

Crashes (16):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets Title
ci2-upstream-fs 2022/10/10 17:12 upstream 493ffd6605b2 5bcf0c31 .config strace log report syz C [disk image] [vmlinux] [mounted in repro] general protection fault in ntfs_fill_super
ci-upstream-kasan-gce-root 2022/10/20 15:31 upstream 55be6084c8e0 b31320fc .config strace log report syz C [disk image] [vmlinux] [mounted in repro] general protection fault in ntfs_fill_super
ci-upstream-kasan-gce-root 2022/10/12 17:17 upstream 55be6084c8e0 89b5a509 .config console log report info [disk image] [vmlinux] KASAN: slab-out-of-bounds Read in ntfs_fill_super
ci-upstream-kasan-gce-root 2022/10/10 19:43 upstream 4899a36f91a9 aea5da89 .config console log report info [disk image] [vmlinux] KASAN: slab-out-of-bounds Read in ntfs_fill_super
ci-upstream-kasan-gce-root 2022/10/01 08:59 upstream ffb4d94b4314 feb56351 .config console log report info [disk image] [vmlinux] KASAN: slab-out-of-bounds Read in ntfs_fill_super
ci2-upstream-fs 2022/11/13 05:49 upstream fef7fd48922d f42ee5d8 .config console log report info [disk image] [vmlinux] [kernel image] KASAN: slab-out-of-bounds Write in ntfs_fill_super
ci2-upstream-fs 2022/10/23 07:03 upstream 4da34b7d175d c0b80a55 .config console log report info [disk image] [vmlinux] general protection fault in ntfs_fill_super
ci2-upstream-fs 2022/10/17 20:44 upstream 493ffd6605b2 94744d21 .config console log report info [disk image] [vmlinux] general protection fault in ntfs_fill_super
ci2-upstream-fs 2022/10/11 07:06 upstream 493ffd6605b2 5bcf0c31 .config console log report info [disk image] [vmlinux] general protection fault in ntfs_fill_super
ci2-upstream-fs 2022/10/10 15:41 upstream 493ffd6605b2 5bcf0c31 .config console log report info [disk image] [vmlinux] general protection fault in ntfs_fill_super
ci2-upstream-fs 2022/10/10 05:02 upstream 4899a36f91a9 aea5da89 .config console log report info [disk image] [vmlinux] general protection fault in ntfs_fill_super
ci2-upstream-fs 2022/10/07 21:40 upstream 4c86114194e6 79a59635 .config console log report info [disk image] [vmlinux] KASAN: stack-out-of-bounds Read in ntfs_fill_super
ci2-upstream-fs 2022/10/07 13:11 upstream 4c86114194e6 79a59635 .config console log report info [disk image] [vmlinux] KASAN: stack-out-of-bounds Read in ntfs_fill_super
ci2-upstream-fs 2022/10/07 06:37 upstream 833477fce7a1 80b58a42 .config console log report info [disk image] [vmlinux] KASAN: stack-out-of-bounds Read in ntfs_fill_super
ci2-upstream-fs 2022/10/07 03:17 upstream 833477fce7a1 80b58a42 .config console log report info [disk image] [vmlinux] KASAN: stack-out-of-bounds Read in ntfs_fill_super
ci2-upstream-fs 2022/10/06 20:29 upstream 833477fce7a1 80b58a42 .config console log report info [disk image] [vmlinux] KASAN: stack-out-of-bounds Read in ntfs_fill_super
* Struck through repros no longer work on HEAD.