syzbot


general protection fault in ima_post_path_mknod

Status: fixed on 2024/11/11 09:26
Bug presence: origin:lts-only
[Documentation on labels]
Reported-by: syzbot+1ffada264154dd758bb9@syzkaller.appspotmail.com
Fix commit: 4a1d95fc9706 udf: Don't return bh from udf_expand_dir_adinicb()
First crash: 47d, last: 47d
Fix bisection: fixed by (bisect log) :
commit 4a1d95fc9706b2b065e56d5281b380bcaa1bce9c
Author: Jan Kara <jack@suse.cz>
Date: Thu Oct 17 20:20:01 2024 +0000

  udf: Don't return bh from udf_expand_dir_adinicb()

  
Bug presence (2)
Date Name Commit Repro Result
2024/10/07 linux-5.15.y (ToT) 3a5928702e71 C [report] general protection fault in ima_post_path_mknod
2024/10/07 upstream (ToT) 8cf0b93919e1 C Didn't crash
Last patch testing requests (3)
Created Duration User Patch Repo Result
2024/10/23 19:20 18m retest repro linux-5.15.y OK log
2024/10/23 19:20 18m retest repro linux-5.15.y OK log
2024/10/23 19:20 19m retest repro linux-5.15.y OK log

Sample crash report:
loop0: rw=2049, want=2052, limit=2048
Buffer I/O error on dev loop0, logical block 1025, lost async page write
attempt to access beyond end of device
loop0: rw=2049, want=2052, limit=2048
Buffer I/O error on dev loop0, logical block 1025, lost async page write
attempt to access beyond end of device
loop0: rw=2049, want=2054, limit=2048
Buffer I/O error on dev loop0, logical block 1026, lost async page write
general protection fault, probably for non-canonical address 0xdffffc0000000000: 0000 [#1] PREEMPT SMP KASAN
KASAN: null-ptr-deref in range [0x0000000000000000-0x0000000000000007]
CPU: 0 PID: 3563 Comm: syz-executor294 Not tainted 5.15.167-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
RIP: 0010:ima_post_path_mknod+0x6e/0x160 security/integrity/ima/ima_main.c:676
Code: 0f b6 04 38 84 c0 0f 85 c5 00 00 00 8b 2d 3a 2d d0 12 31 ff 89 ee e8 61 d3 af fd 85 ed 0f 84 8d 00 00 00 48 89 d8 48 c1 e8 03 <42> 0f b6 04 38 84 c0 0f 85 c0 00 00 00 0f b7 2b 81 e5 00 f0 00 00
RSP: 0018:ffffc90002eb7dd8 EFLAGS: 00010246
RAX: 0000000000000000 RBX: 0000000000000000 RCX: ffffffff96a0b703
RDX: ffff8880282ad940 RSI: 0000000000000001 RDI: 0000000000000000
RBP: 0000000000000001 R08: ffffffff83d08a6f R09: ffffed1003ee20fb
R10: 0000000000000000 R11: dffffc0000000001 R12: ffffc90002eb7e80
R13: dffffc0000000000 R14: ffffffff8c7cd520 R15: dffffc0000000000
FS:  000055556c6e6380(0000) GS:ffff8880b9000000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00005632d8e77ff8 CR3: 000000001ef77000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 do_mknodat+0x41d/0x690 fs/namei.c:3997
 __do_sys_mknod fs/namei.c:4027 [inline]
 __se_sys_mknod fs/namei.c:4025 [inline]
 __x64_sys_mknod+0x8a/0xa0 fs/namei.c:4025
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3b/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x66/0xd0
RIP: 0033:0x7f6fbdc4ea39
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 61 17 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:00007ffdf4b492d8 EFLAGS: 00000246 ORIG_RAX: 0000000000000085
RAX: ffffffffffffffda RBX: 00007ffdf4b494b8 RCX: 00007f6fbdc4ea39
RDX: 0000000000000701 RSI: 0000000000000000 RDI: 0000000020000000
RBP: 00007f6fbdcc3610 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000001
R13: 00007ffdf4b494a8 R14: 0000000000000001 R15: 0000000000000001
 </TASK>
Modules linked in:
---[ end trace 14ca79e81204b070 ]---
RIP: 0010:ima_post_path_mknod+0x6e/0x160 security/integrity/ima/ima_main.c:676
Code: 0f b6 04 38 84 c0 0f 85 c5 00 00 00 8b 2d 3a 2d d0 12 31 ff 89 ee e8 61 d3 af fd 85 ed 0f 84 8d 00 00 00 48 89 d8 48 c1 e8 03 <42> 0f b6 04 38 84 c0 0f 85 c0 00 00 00 0f b7 2b 81 e5 00 f0 00 00
RSP: 0018:ffffc90002eb7dd8 EFLAGS: 00010246
RAX: 0000000000000000 RBX: 0000000000000000 RCX: ffffffff96a0b703
RDX: ffff8880282ad940 RSI: 0000000000000001 RDI: 0000000000000000
RBP: 0000000000000001 R08: ffffffff83d08a6f R09: ffffed1003ee20fb
R10: 0000000000000000 R11: dffffc0000000001 R12: ffffc90002eb7e80
R13: dffffc0000000000 R14: ffffffff8c7cd520 R15: dffffc0000000000
FS:  000055556c6e6380(0000) GS:ffff8880b9000000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00005632d8e77ff8 CR3: 000000001ef77000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
   0:	0f b6 04 38          	movzbl (%rax,%rdi,1),%eax
   4:	84 c0                	test   %al,%al
   6:	0f 85 c5 00 00 00    	jne    0xd1
   c:	8b 2d 3a 2d d0 12    	mov    0x12d02d3a(%rip),%ebp        # 0x12d02d4c
  12:	31 ff                	xor    %edi,%edi
  14:	89 ee                	mov    %ebp,%esi
  16:	e8 61 d3 af fd       	call   0xfdafd37c
  1b:	85 ed                	test   %ebp,%ebp
  1d:	0f 84 8d 00 00 00    	je     0xb0
  23:	48 89 d8             	mov    %rbx,%rax
  26:	48 c1 e8 03          	shr    $0x3,%rax
* 2a:	42 0f b6 04 38       	movzbl (%rax,%r15,1),%eax <-- trapping instruction
  2f:	84 c0                	test   %al,%al
  31:	0f 85 c0 00 00 00    	jne    0xf7
  37:	0f b7 2b             	movzwl (%rbx),%ebp
  3a:	81 e5 00 f0 00 00    	and    $0xf000,%ebp

Crashes (5):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/10/07 02:47 linux-5.15.y 3a5928702e71 d7906eff .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan general protection fault in ima_post_path_mknod
2024/10/07 01:59 linux-5.15.y 3a5928702e71 d7906eff .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan general protection fault in ima_post_path_mknod
2024/10/07 01:15 linux-5.15.y 3a5928702e71 d7906eff .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan general protection fault in ima_post_path_mknod
2024/10/07 00:31 linux-5.15.y 3a5928702e71 d7906eff .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan general protection fault in ima_post_path_mknod
2024/10/06 23:40 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan general protection fault in ima_post_path_mknod
* Struck through repros no longer work on HEAD.