syzbot


KASAN: wild-memory-access Read in hfsplus_bnode_dump

Status: upstream: reported C repro on 2023/06/26 13:24
Bug presence: origin:upstream
[Documentation on labels]
Reported-by: syzbot+bdc3a7bca646e3321ee5@syzkaller.appspotmail.com
First crash: 312d, last: 2d13h
Bug presence (1)
Date Name Commit Repro Result
2023/06/26 upstream (ToT) a0433f8cae3a C [report] KASAN: wild-memory-access Read in hfsplus_bnode_dump
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KASAN: wild-memory-access Read in hfsplus_bnode_dump hfs C error error 23 1d15h 382d 0/26 upstream: reported C repro on 2023/04/17 05:34
Fix bisection attempts (5)
Created Duration User Patch Repo Result
2024/02/17 13:06 1h31m bisect fix linux-6.1.y job log (0) log
2024/01/09 16:32 1h05m bisect fix linux-6.1.y job log (0) log
2023/12/10 15:23 1h07m bisect fix linux-6.1.y job log (0) log
2023/11/10 08:45 2h22m bisect fix linux-6.1.y job log (0) log
2023/10/06 16:58 1h41m bisect fix linux-6.1.y job log (0) log

Sample crash report:
loop0: detected capacity change from 0 to 1024
hfsplus: request for non-existent node 32768 in B*Tree
hfsplus: request for non-existent node 32768 in B*Tree
==================================================================
BUG: KASAN: wild-memory-access in memcpy_from_page include/linux/highmem.h:367 [inline]
BUG: KASAN: wild-memory-access in hfsplus_bnode_read fs/hfsplus/bnode.c:32 [inline]
BUG: KASAN: wild-memory-access in hfsplus_bnode_read_u16 fs/hfsplus/bnode.c:45 [inline]
BUG: KASAN: wild-memory-access in hfsplus_bnode_dump+0x3ff/0xba0 fs/hfsplus/bnode.c:305
Read of size 2 at addr 000508800000103e by task syz-executor394/3540

CPU: 0 PID: 3540 Comm: syz-executor394 Not tainted 6.1.35-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/27/2023
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1e3/0x2cb lib/dump_stack.c:106
 print_report+0xe6/0x4f0 mm/kasan/report.c:398
 kasan_report+0x136/0x160 mm/kasan/report.c:495
 kasan_check_range+0x27f/0x290 mm/kasan/generic.c:189
 memcpy+0x25/0x60 mm/kasan/shadow.c:65
 memcpy_from_page include/linux/highmem.h:367 [inline]
 hfsplus_bnode_read fs/hfsplus/bnode.c:32 [inline]
 hfsplus_bnode_read_u16 fs/hfsplus/bnode.c:45 [inline]
 hfsplus_bnode_dump+0x3ff/0xba0 fs/hfsplus/bnode.c:305
 hfsplus_brec_remove+0x428/0x4e0 fs/hfsplus/brec.c:229
 __hfsplus_delete_attr+0x271/0x450 fs/hfsplus/attributes.c:299
 hfsplus_delete_all_attrs+0x267/0x3c0 fs/hfsplus/attributes.c:378
 hfsplus_delete_cat+0xb83/0xfb0 fs/hfsplus/catalog.c:425
 hfsplus_unlink+0x35f/0x7f0 fs/hfsplus/dir.c:385
 vfs_unlink+0x359/0x5f0 fs/namei.c:4252
 do_unlinkat+0x49d/0x940 fs/namei.c:4320
 __do_sys_unlink fs/namei.c:4368 [inline]
 __se_sys_unlink fs/namei.c:4366 [inline]
 __x64_sys_unlink+0x45/0x50 fs/namei.c:4366
 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:0x7fb28f70b799
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 51 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 c0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffc792b3e58 EFLAGS: 00000246 ORIG_RAX: 0000000000000057
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007fb28f70b799
RDX: 00007fb28f6c9e13 RSI: 0000000000000000 RDI: 0000000020000140
RBP: 00007fb28f6cb030 R08: 0000000000000640 R09: 0000000000000000
R10: 00007ffc792b3d20 R11: 0000000000000246 R12: 00007fb28f6cb0c0
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
 </TASK>
==================================================================

Crashes (10):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/06/26 13:24 linux-6.1.y e84a4e368abe 79782afc .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: wild-memory-access Read in hfsplus_bnode_dump
2023/08/12 22:19 linux-6.1.y 1321ab403b38 39990d51 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: wild-memory-access Read in hfsplus_bnode_dump
2024/03/11 12:37 linux-6.1.y 61adba85cc40 6ee49f2e .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in hfsplus_bnode_dump
2024/04/19 23:04 linux-6.1.y 6741e066ec76 af24b050 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: wild-memory-access Read in hfsplus_bnode_dump
2024/03/18 17:59 linux-6.1.y d7543167affd baa80228 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: wild-memory-access Read in hfsplus_bnode_dump
2024/03/18 16:14 linux-6.1.y d7543167affd baa80228 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: wild-memory-access Read in hfsplus_bnode_dump
2024/05/01 11:57 linux-6.1.y dcbc050cb0d3 3ba885bc .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in hfsplus_bnode_dump
2024/04/20 12:47 linux-6.1.y 6741e066ec76 af24b050 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in hfsplus_bnode_dump
2024/04/17 00:17 linux-6.1.y cd5d98c0556c 18f6e127 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in hfsplus_bnode_dump
2024/03/11 12:15 linux-6.1.y 61adba85cc40 6ee49f2e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in hfsplus_bnode_dump
* Struck through repros no longer work on HEAD.