syzbot


WARNING in udf_expand_dir_adinicb

Status: fixed on 2023/06/08 14:41
Subsystems: udf
[Documentation on labels]
Reported-by: syzbot+111eaa994ff74f8d440f@syzkaller.appspotmail.com
Fix commit: df97f64dfa31 udf: Avoid directory type conversion failure due to ENOMEM
First crash: 445d, last: 445d
Cause bisection: introduced by (bisect log) :
commit 0aba4860b0d0216a1a300484ff536171894d49d8
Author: Jan Kara <jack@suse.cz>
Date: Tue Dec 20 11:38:45 2022 +0000

  udf: Allocate name buffer in directory iterator on heap

Crash: WARNING in udf_expand_dir_adinicb (log)
Repro: C syz .config
  
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [udf?] WARNING in udf_expand_dir_adinicb 0 (1) 2023/02/09 04:57

Sample crash report:
RSP: 002b:00007ffedf8b9a28 EFLAGS: 00000246 ORIG_RAX: 0000000000000085
RAX: ffffffffffffffda RBX: 0000000000000002 RCX: 00007fcaa035f9a9
RDX: 0000000000000701 RSI: 0000000000000000 RDI: 0000000020000200
RBP: 00007ffedf8b9a50 R08: 0000000000000002 R09: 00007ffedf8b9a60
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000004
R13: 00007ffedf8b9a90 R14: 00007ffedf8b9a70 R15: 000000000000000c
 </TASK>
------------[ cut here ]------------
WARNING: CPU: 0 PID: 5101 at fs/udf/namei.c:220 udf_expand_dir_adinicb+0xbd8/0xe00 fs/udf/namei.c:220
Modules linked in:
CPU: 0 PID: 5101 Comm: syz-executor305 Not tainted 6.2.0-rc6-next-20230203-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/12/2023
RIP: 0010:udf_expand_dir_adinicb+0xbd8/0xe00 fs/udf/namei.c:220
Code: 89 44 24 18 e8 49 21 ee fe 4c 8b 44 24 18 e9 c9 f9 ff ff e8 8a 1d 9f fe 4c 89 ef e8 b2 99 0d ff e9 20 f8 ff ff e8 78 1d 9f fe <0f> 0b e9 fd fd ff ff 41 bc 8b ff ff ff e9 56 f6 ff ff 41 bc f4 ff
RSP: 0018:ffffc90003d0f858 EFLAGS: 00010293
RAX: 0000000000000000 RBX: 00000000fffffff4 RCX: 0000000000000000
RDX: ffff88801d95d7c0 RSI: ffffffff82e54d28 RDI: 0000000000000005
RBP: ffff8880741e0158 R08: 0000000000000005 R09: 0000000000000000
R10: 00000000fffffff4 R11: 0000000000000000 R12: 00000000fffffff4
R13: ffff888074218910 R14: ffffc90003d0f928 R15: 0000000000000000
FS:  0000555555946300(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fcaa0334610 CR3: 0000000017f44000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 udf_fiiter_add_entry+0xcf2/0x1080 fs/udf/namei.c:270
 udf_add_nondir+0xdb/0x3a0 fs/udf/namei.c:361
 udf_create+0xda/0x120 fs/udf/namei.c:394
 vfs_create fs/namei.c:3118 [inline]
 vfs_create+0x1a9/0x3a0 fs/namei.c:3102
 do_mknodat+0x3d9/0x530 fs/namei.c:3966
 __do_sys_mknod fs/namei.c:3999 [inline]
 __se_sys_mknod fs/namei.c:3997 [inline]
 __x64_sys_mknod+0x11e/0x180 fs/namei.c:3997
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x39/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7fcaa035f9a9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 11 15 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:00007ffedf8b9a28 EFLAGS: 00000246 ORIG_RAX: 0000000000000085
RAX: ffffffffffffffda RBX: 0000000000000002 RCX: 00007fcaa035f9a9
RDX: 0000000000000701 RSI: 0000000000000000 RDI: 0000000020000200
RBP: 00007ffedf8b9a50 R08: 0000000000000002 R09: 00007ffedf8b9a60
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000004
R13: 00007ffedf8b9a90 R14: 00007ffedf8b9a70 R15: 000000000000000c
 </TASK>

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/02/05 05:04 linux-next 4fafd96910ad be607b78 .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-linux-next-kasan-gce-root WARNING in udf_expand_dir_adinicb
2023/02/05 04:47 linux-next 4fafd96910ad be607b78 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in udf_expand_dir_adinicb
* Struck through repros no longer work on HEAD.