syzbot


BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster

Status: fixed on 2023/02/24 13:51
Subsystems: ntfs3 (incorrect?)
Reported-by: syzbot+deb631beeb93bdb2df4c@syzkaller.appspotmail.com
Fix commit: c380b52f6c57 fs/ntfs3: Change new sparse cluster processing
First crash: 98d, last: 91d

Cause bisection: failed (error log, bisect log)

Fix bisection: fixed by (bisect log) :
commit c380b52f6c5702cc4bdda5e6d456d6c19a201a0b
Author: Konstantin Komarov <almaz.alexandrovich@paragon-software.com>
Date: Fri Oct 7 11:02:36 2022 +0000

  fs/ntfs3: Change new sparse cluster processing

similar bugs (2):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-6.1 BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster 10 8h44m 6d23h 0/3 upstream: reported on 2023/03/15 20:23
linux-5.15 BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster 15 1d16h 6d22h 0/3 upstream: reported on 2023/03/15 20:30

Sample crash report:
BUG: kernel NULL pointer dereference, address: 0000000000000000
#PF: supervisor instruction fetch in kernel mode
#PF: error_code(0x0010) - not-present page
PGD 217c0067 P4D 217c0067 PUD 1e4e8067 PMD 0 
Oops: 0010 [#1] PREEMPT SMP KASAN
CPU: 0 PID: 5302 Comm: syz-executor244 Not tainted 6.1.0-syzkaller-09941-ge2ca6ba6ba01 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022
RIP: 0010:0x0
Code: Unable to access opcode bytes at 0xffffffffffffffd6.
RSP: 0018:ffffc90003c1fca8 EFLAGS: 00010286
RAX: 0000000000000000 RBX: dffffc0000000000 RCX: ffff8880268b8000
RDX: 0000000000000000 RSI: ffffea0001c79440 RDI: ffff888075eb0478
RBP: ffffea0001c79440 R08: ffffffff81bc12ab R09: fffff9400038f289
R10: fffff9400038f289 R11: 1ffffd400038f288 R12: 0000000000000000
R13: 0000000000010000 R14: 1ffffd400038f288 R15: ffffffffffffffff
FS:  00007f45fe7d4700(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffffffffffd6 CR3: 000000002986e000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 ntfs_sparse_cluster+0x767/0xa90 fs/ntfs3/file.c:335
 ntfs_fallocate+0xbc6/0xfb0 fs/ntfs3/file.c:727
 vfs_fallocate+0x515/0x670 fs/open.c:323
 ksys_fallocate fs/open.c:346 [inline]
 __do_sys_fallocate fs/open.c:354 [inline]
 __se_sys_fallocate fs/open.c:352 [inline]
 __x64_sys_fallocate+0xb9/0x100 fs/open.c:352
 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:0x7f4606a484c9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 b1 14 00 00 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 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f45fe7d4308 EFLAGS: 00000246 ORIG_RAX: 000000000000011d
RAX: ffffffffffffffda RBX: 00007f4606aec6f8 RCX: 00007f4606a484c9
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000006
RBP: 00007f4606aec6f0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000010000 R11: 0000000000000246 R12: 00007f4606aec6fc
R13: 00007f4606ab93d8 R14: 0030656c69662f2e R15: 0000000000022000
 </TASK>
Modules linked in:
CR2: 0000000000000000
---[ end trace 0000000000000000 ]---
RIP: 0010:0x0
Code: Unable to access opcode bytes at 0xffffffffffffffd6.
RSP: 0018:ffffc90003c1fca8 EFLAGS: 00010286
RAX: 0000000000000000 RBX: dffffc0000000000 RCX: ffff8880268b8000
RDX: 0000000000000000 RSI: ffffea0001c79440 RDI: ffff888075eb0478
RBP: ffffea0001c79440 R08: ffffffff81bc12ab R09: fffff9400038f289
R10: fffff9400038f289 R11: 1ffffd400038f288 R12: 0000000000000000
R13: 0000000000010000 R14: 1ffffd400038f288 R15: ffffffffffffffff
FS:  00007f45fe7d4700(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffffffffffd6 CR3: 000000002986e000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400

Crashes (11):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets Title
ci2-upstream-fs 2022/12/14 15:51 upstream e2ca6ba6ba01 b18f0a64 .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster
ci2-upstream-fs 2022/12/21 00:28 upstream 6feb57c2fd7c d3e76707 .config console log report info [disk image] [vmlinux] [kernel image] BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster
ci2-upstream-fs 2022/12/20 23:47 upstream 6feb57c2fd7c d3e76707 .config console log report info [disk image] [vmlinux] [kernel image] BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster
ci2-upstream-fs 2022/12/20 12:25 upstream aeba12b26c79 c52b2efb .config console log report info [disk image] [vmlinux] [kernel image] BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster
ci2-upstream-fs 2022/12/19 11:20 upstream f9ff5644bcc0 05494336 .config console log report info [disk image] [vmlinux] [kernel image] BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster
ci2-upstream-fs 2022/12/19 02:57 upstream f9ff5644bcc0 05494336 .config console log report info [disk image] [vmlinux] [kernel image] BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster
ci2-upstream-fs 2022/12/17 21:07 upstream 77856d911a8c 05494336 .config console log report info [disk image] [vmlinux] [kernel image] BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster
ci2-upstream-fs 2022/12/17 20:16 upstream 77856d911a8c 05494336 .config console log report info [disk image] [vmlinux] [kernel image] BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster
ci2-upstream-fs 2022/12/15 22:38 upstream 041fae9c105a 6f9c033e .config console log report info [disk image] [vmlinux] [kernel image] BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster
ci2-upstream-fs 2022/12/15 03:12 upstream e2ca6ba6ba01 b18f0a64 .config console log report info [disk image] [vmlinux] [kernel image] BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster
ci2-upstream-fs 2022/12/14 15:34 upstream e2ca6ba6ba01 b18f0a64 .config console log report info [disk image] [vmlinux] [kernel image] BUG: unable to handle kernel NULL pointer dereference in ntfs_sparse_cluster
* Struck through repros no longer work on HEAD.