syzbot


KASAN: global-out-of-bounds Read in pid_task (3)

Status: moderation: reported on 2025/09/17 19:48
Subsystems: kernel
[Documentation on labels]
Reported-by: syzbot+87ba2e47435f2c45ad11@syzkaller.appspotmail.com
First crash: 35d, last: 14d
Similar bugs (2)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KASAN: global-out-of-bounds Read in pid_task (2) gfs2 17 1 117d 113d 0/29 auto-obsoleted due to no activity on 2025/08/23 04:56
upstream KASAN: global-out-of-bounds Read in pid_task kernel 17 1 460d 456d 0/29 auto-obsoleted due to no activity on 2024/10/14 08:08

Sample crash report:
gfs2: fsid=syz:syz.0:  H: s:SH f: e:0 p:7762 [syz.8.300] iterate_dir+0x399/0x570 fs/readdir.c:108
gfs2: fsid=syz:syz.0:  H: s:SH f: e:0 p:7762 [syz.8.300] iterate_dir+0x399/0x570 fs/readdir.c:108
gfs2: fsid=syz:syz.0:  H: s:SH f: e:0 p:7762 [syz.8.300] iterate_dir+0x399/0x570 fs/readdir.c:108
gfs2: fsid=syz:syz.0:  H: s:SH f: e:0 p:7762 [syz.8.300] iterate_dir+0x399/0x570 fs/readdir.c:108
gfs2: fsid=syz:syz.0:  H: s:SH f: e:0 p:7762 [syz.8.300] iterate_dir+0x399/0x570 fs/readdir.c:108
==================================================================
BUG: KASAN: global-out-of-bounds in pid_task+0x5a/0x140 kernel/pid.c:419
Read of size 8 at addr ffffffff9251d918 by task syz.8.300/7764

CPU: 0 UID: 0 PID: 7764 Comm: syz.8.300 Not tainted syzkaller #0 PREEMPT(full) 
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/18/2025
Call Trace:
 <TASK>
 dump_stack_lvl+0x189/0x250 lib/dump_stack.c:120
 print_address_description mm/kasan/report.c:378 [inline]
 print_report+0xca/0x240 mm/kasan/report.c:482
 kasan_report+0x118/0x150 mm/kasan/report.c:595
 pid_task+0x5a/0x140 kernel/pid.c:419
 dump_holder fs/gfs2/glock.c:2283 [inline]
 gfs2_dump_glock+0x10b4/0x1bc0 fs/gfs2/glock.c:2398
 gfs2_consist_inode_i+0xf5/0x110 fs/gfs2/util.c:446
 gfs2_dirent_scan+0x545/0x690 fs/gfs2/dir.c:-1
 gfs2_dirent_search+0x2cb/0x710 fs/gfs2/dir.c:854
 gfs2_dir_search+0x4c/0x220 fs/gfs2/dir.c:1651
 gfs2_lookupi+0x3d9/0x5a0 fs/gfs2/inode.c:340
 __gfs2_lookup+0x8f/0x270 fs/gfs2/inode.c:975
 __lookup_slow+0x297/0x3d0 fs/namei.c:1816
 lookup_slow+0x53/0x70 fs/namei.c:1833
 walk_component+0x2d2/0x400 fs/namei.c:2151
 lookup_last fs/namei.c:2652 [inline]
 path_lookupat+0x163/0x430 fs/namei.c:2676
 filename_lookup+0x212/0x570 fs/namei.c:2705
 vfs_statx+0xf8/0x550 fs/stat.c:353
 vfs_fstatat+0x118/0x170 fs/stat.c:375
 __do_sys_newfstatat fs/stat.c:542 [inline]
 __se_sys_newfstatat fs/stat.c:536 [inline]
 __x64_sys_newfstatat+0x116/0x190 fs/stat.c:536
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0xfa/0xfa0 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fc8d498eec9
Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 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 a8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fc8d58b3038 EFLAGS: 00000246 ORIG_RAX: 0000000000000106
RAX: ffffffffffffffda RBX: 00007fc8d4be6090 RCX: 00007fc8d498eec9
RDX: 0000000000000000 RSI: 0000200000000200 RDI: ffffffffffffff9c
RBP: 00007fc8d4a11f91 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000001000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fc8d4be6128 R14: 00007fc8d4be6090 R15: 00007ffc67293f58
 </TASK>

The buggy address belongs to the variable:
 copy_signal.__key.111+0x18/0x20

The buggy address belongs to the physical page:
page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1251d
flags: 0xfff00000002000(reserved|node=0|zone=1|lastcpupid=0x7ff)
raw: 00fff00000002000 ffffea0000494748 ffffea0000494748 0000000000000000
raw: 0000000000000000 0000000000000000 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner info is not present (never set?)

Memory state around the buggy address:
 ffffffff9251d800: 00 00 f9 f9 00 00 f9 f9 00 00 f9 f9 00 00 f9 f9
 ffffffff9251d880: 00 00 f9 f9 00 00 f9 f9 00 00 f9 f9 00 00 f9 f9
>ffffffff9251d900: 00 00 f9 f9 00 00 f9 f9 00 00 f9 f9 00 00 f9 f9
                            ^
 ffffffff9251d980: 00 00 f9 f9 00 00 f9 f9 00 00 f9 f9 00 00 f9 f9
 ffffffff9251da00: 00 00 f9 f9 00 00 f9 f9 01 f9 f9 f9 00 f9 f9 f9
==================================================================

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/10/05 08:06 linux-next 47a8d4b89844 49379ee0 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root KASAN: global-out-of-bounds Read in pid_task
2025/09/13 19:45 linux-next 590b221ed425 e2beed91 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root KASAN: global-out-of-bounds Read in pid_task
* Struck through repros no longer work on HEAD.