syzbot


KASAN: use-after-free Read in sysv_new_inode

Status: upstream: reported C repro on 2024/04/22 17:59
Bug presence: origin:upstream
[Documentation on labels]
Reported-by: syzbot+bdff56916773908c2fcc@syzkaller.appspotmail.com
First crash: 281d, last: 5h37m
Bug presence (1)
Date Name Commit Repro Result
2024/10/30 upstream (ToT) e42b1a9a2557 C [report] KASAN: use-after-free Read in sysv_new_inode
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KASAN: use-after-free Read in sysv_new_inode fs 1 358d 354d 0/28 auto-obsoleted due to no activity on 2024/04/05 09:37
upstream KASAN: use-after-free Read in sysv_new_inode (2) fs C inconclusive 12218 45m 264d 0/28 upstream: reported C repro on 2024/05/09 07:33
linux-5.15 KASAN: use-after-free Read in sysv_new_inode C 1318 22m 289d 0/3 upstream: reported C repro on 2024/04/14 13:45
Fix bisection attempts (1)
Created Duration User Patch Repo Result
2024/09/09 15:20 1h15m bisect fix linux-6.1.y OK (0) job log log

Sample crash report:
==================================================================
BUG: KASAN: use-after-free in sysv_new_inode+0x107e/0x1210 fs/sysv/ialloc.c:153
Read of size 2 at addr ffff88806e1321ce by task syz-executor256/4251

CPU: 1 PID: 4251 Comm: syz-executor256 Not tainted 6.1.126-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 12/27/2024
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1e3/0x2cb lib/dump_stack.c:106
 print_address_description mm/kasan/report.c:316 [inline]
 print_report+0x15f/0x4f0 mm/kasan/report.c:427
 kasan_report+0x136/0x160 mm/kasan/report.c:531
 sysv_new_inode+0x107e/0x1210 fs/sysv/ialloc.c:153
 sysv_symlink+0x9b/0x180 fs/sysv/namei.c:80
 vfs_symlink+0x247/0x3d0 fs/namei.c:4471
 do_symlinkat+0x21e/0x390 fs/namei.c:4500
 __do_sys_symlinkat fs/namei.c:4517 [inline]
 __se_sys_symlinkat fs/namei.c:4514 [inline]
 __x64_sys_symlinkat+0x95/0xa0 fs/namei.c:4514
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x3b/0xb0 arch/x86/entry/common.c:81
 entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7f5c159da839
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 81 18 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 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f5c15997218 EFLAGS: 00000246 ORIG_RAX: 000000000000010a
RAX: ffffffffffffffda RBX: 00007f5c15a6b6c8 RCX: 00007f5c159da839
RDX: 0000000020000340 RSI: 0000000000000004 RDI: 0000000020000440
RBP: 00007f5c15a6b6c0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00007f5c15a37f70
R13: 00007f5c15a2e0e0 R14: 00007f5c15a2e088 R15: 00007f5c15a2e07e
 </TASK>

The buggy address belongs to the physical page:
page:ffffea0001b84c80 refcount:0 mapcount:0 mapping:0000000000000000 index:0x1 pfn:0x6e132
flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff)
raw: 00fff00000000000 ffffea0001b84cc8 ffffea0001b84c48 0000000000000000
raw: 0000000000000001 0000000000000000 00000000ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner tracks the page as freed
page last allocated via order 0, migratetype Movable, gfp_mask 0x140dca(GFP_HIGHUSER_MOVABLE|__GFP_COMP|__GFP_ZERO), pid 4234, tgid 4234 (sshd), ts 61922261166, free_ts 61955565874
 set_page_owner include/linux/page_owner.h:31 [inline]
 post_alloc_hook+0x18d/0x1b0 mm/page_alloc.c:2532
 prep_new_page mm/page_alloc.c:2539 [inline]
 get_page_from_freelist+0x3731/0x38d0 mm/page_alloc.c:4328
 __alloc_pages+0x28d/0x770 mm/page_alloc.c:5605
 __folio_alloc+0xf/0x30 mm/page_alloc.c:5637
 vma_alloc_folio+0x486/0x990 mm/mempolicy.c:2243
 alloc_page_vma include/linux/gfp.h:284 [inline]
 do_anonymous_page mm/memory.c:4189 [inline]
 handle_pte_fault mm/memory.c:5027 [inline]
 __handle_mm_fault mm/memory.c:5171 [inline]
 handle_mm_fault+0x2e8e/0x5340 mm/memory.c:5292
 do_user_addr_fault arch/x86/mm/fault.c:1340 [inline]
 handle_page_fault arch/x86/mm/fault.c:1431 [inline]
 exc_page_fault+0x26f/0x620 arch/x86/mm/fault.c:1487
 asm_exc_page_fault+0x22/0x30 arch/x86/include/asm/idtentry.h:608
page last free stack trace:
 reset_page_owner include/linux/page_owner.h:24 [inline]
 free_pages_prepare mm/page_alloc.c:1459 [inline]
 free_pcp_prepare mm/page_alloc.c:1509 [inline]
 free_unref_page_prepare+0x12a6/0x15b0 mm/page_alloc.c:3384
 free_unref_page_list+0x663/0x900 mm/page_alloc.c:3525
 release_pages+0x24c4/0x27a0 mm/swap.c:1035
 tlb_batch_pages_flush mm/mmu_gather.c:59 [inline]
 tlb_flush_mmu_free mm/mmu_gather.c:254 [inline]
 tlb_flush_mmu+0xfc/0x210 mm/mmu_gather.c:261
 tlb_finish_mmu+0xce/0x1f0 mm/mmu_gather.c:361
 unmap_region+0x29f/0x2f0 mm/mmap.c:2331
 do_mas_align_munmap+0xef5/0x15a0 mm/mmap.c:2580
 do_mas_munmap+0x246/0x2b0 mm/mmap.c:2638
 __vm_munmap+0x268/0x370 mm/mmap.c:2924
 __do_sys_munmap mm/mmap.c:2949 [inline]
 __se_sys_munmap mm/mmap.c:2946 [inline]
 __x64_sys_munmap+0x5c/0x70 mm/mmap.c:2946
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x3b/0xb0 arch/x86/entry/common.c:81
 entry_SYSCALL_64_after_hwframe+0x68/0xd2

Memory state around the buggy address:
 ffff88806e132080: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
 ffff88806e132100: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
>ffff88806e132180: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
                                              ^
 ffff88806e132200: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
 ffff88806e132280: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
==================================================================

Crashes (1239):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/01/22 09:30 linux-6.1.y f4f677285b38 da72ac06 .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/19 23:34 linux-6.1.y f4f677285b38 f2cb035c .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/05 23:30 linux-6.1.y 7dc732d24ff7 f3558dbf .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2024/12/02 05:37 linux-6.1.y e4d90d63d385 68914665 .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2024/11/30 12:37 linux-6.1.y e4d90d63d385 68914665 .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2024/10/28 13:49 linux-6.1.y 7ec6f9fa3d97 65e8686b .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2024/10/28 13:17 linux-6.1.y 7ec6f9fa3d97 65e8686b .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/25 20:22 linux-6.1.y 75cefdf153f5 9fbd772e .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2024/05/12 12:28 linux-6.1.y 909ba1f1b414 9026e142 .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 sysv_new_inode
2024/04/28 01:54 linux-6.1.y f2295faba5e8 07b455f9 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan-arm64 KASAN: slab-out-of-bounds Read in sysv_new_inode
2024/12/12 00:10 linux-6.1.y e4d90d63d385 ff949d25 .config console log report syz / log [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2024/11/30 15:13 linux-6.1.y e4d90d63d385 68914665 .config console log report syz / log [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2024/11/25 01:21 linux-6.1.y e4d90d63d385 68da6d95 .config console log report syz / log [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2024/11/19 13:12 linux-6.1.y b67dc5c9ade9 571351cb .config console log report syz / log [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/28 20:35 linux-6.1.y 75cefdf153f5 f5427d7c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/27 22:51 linux-6.1.y 75cefdf153f5 18070896 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/27 16:12 linux-6.1.y 75cefdf153f5 d99a33ad .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/27 03:27 linux-6.1.y 75cefdf153f5 9fbd772e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/26 19:13 linux-6.1.y 75cefdf153f5 9fbd772e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/25 02:25 linux-6.1.y 75cefdf153f5 1293872d .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/24 06:52 linux-6.1.y 75cefdf153f5 521b0ce3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/24 06:49 linux-6.1.y 75cefdf153f5 521b0ce3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/24 03:30 linux-6.1.y 75cefdf153f5 521b0ce3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/24 02:09 linux-6.1.y 75cefdf153f5 521b0ce3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/23 18:50 linux-6.1.y 75cefdf153f5 521b0ce3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/23 16:35 linux-6.1.y f4f677285b38 a44b0418 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/23 12:52 linux-6.1.y f4f677285b38 a44b0418 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/23 07:49 linux-6.1.y f4f677285b38 a44b0418 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/23 02:10 linux-6.1.y f4f677285b38 a44b0418 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/22 23:23 linux-6.1.y f4f677285b38 a44b0418 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/22 23:23 linux-6.1.y f4f677285b38 a44b0418 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/20 21:48 linux-6.1.y f4f677285b38 6e87cfa2 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/20 15:51 linux-6.1.y f4f677285b38 6e87cfa2 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/20 11:02 linux-6.1.y f4f677285b38 f2cb035c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/20 10:50 linux-6.1.y f4f677285b38 f2cb035c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/20 07:00 linux-6.1.y f4f677285b38 f2cb035c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/19 23:12 linux-6.1.y f4f677285b38 f2cb035c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/19 23:04 linux-6.1.y f4f677285b38 f2cb035c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2024/04/22 17:58 linux-6.1.y 6741e066ec76 36c961ad .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: use-after-free Read in sysv_new_inode
2025/01/29 00:27 linux-6.1.y 75cefdf153f5 f5427d7c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/28 10:05 linux-6.1.y 75cefdf153f5 18070896 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/27 10:10 linux-6.1.y 75cefdf153f5 d99a33ad .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/27 00:40 linux-6.1.y 75cefdf153f5 9fbd772e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/26 16:31 linux-6.1.y 75cefdf153f5 9fbd772e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/26 14:36 linux-6.1.y 75cefdf153f5 9fbd772e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/26 11:53 linux-6.1.y 75cefdf153f5 9fbd772e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/26 08:02 linux-6.1.y 75cefdf153f5 9fbd772e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/26 04:50 linux-6.1.y 75cefdf153f5 9fbd772e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/25 19:10 linux-6.1.y 75cefdf153f5 9fbd772e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/25 04:35 linux-6.1.y 75cefdf153f5 9fbd772e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/24 14:41 linux-6.1.y 75cefdf153f5 1293872d .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/24 08:43 linux-6.1.y 75cefdf153f5 521b0ce3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/24 01:01 linux-6.1.y 75cefdf153f5 521b0ce3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/23 23:51 linux-6.1.y 75cefdf153f5 521b0ce3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/23 18:17 linux-6.1.y 75cefdf153f5 521b0ce3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/23 14:54 linux-6.1.y f4f677285b38 a44b0418 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/23 12:54 linux-6.1.y f4f677285b38 a44b0418 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/23 03:38 linux-6.1.y f4f677285b38 a44b0418 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/23 01:10 linux-6.1.y f4f677285b38 a44b0418 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/22 12:14 linux-6.1.y f4f677285b38 da72ac06 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/21 16:52 linux-6.1.y f4f677285b38 da72ac06 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/21 11:59 linux-6.1.y f4f677285b38 6e87cfa2 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/21 00:58 linux-6.1.y f4f677285b38 6e87cfa2 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2025/01/20 09:46 linux-6.1.y f4f677285b38 f2cb035c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: use-after-free Read in sysv_new_inode
2024/11/05 12:04 linux-6.1.y 7c15117f9468 da38b4c9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan KASAN: out-of-bounds Read in sysv_new_inode
2025/01/12 05:38 linux-6.1.y c63962be84ef 6dbc6a9b .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-arm64 KASAN: slab-out-of-bounds Read in sysv_new_inode
* Struck through repros no longer work on HEAD.