KASAN: slab-use-after-free Read in chrdev_open

Status: auto-obsoleted due to no activity on 2026/09/23 20:58
Subsystems: ntfs3
[Documentation on labels]
Reported-by: syzbot+5d34cc6474499a5ff516@syzkaller.appspotmail.com
First crash: 895d, last: 460d
Cause bisection: introduced by (bisect log) :
commit ef9297007e9904588682699e618c56401f61d1c2
Author: Kari Argillander <kari.argillander@gmail.com>
Date: Thu Sep 2 15:40:49 2021 +0000

  fs/ntfs3: Make binary search to search smaller chunks in beginning

Crash: KASAN: use-after-free Read in chrdev_open (log)
Repro: C syz .config
  
Fix bisection: failed (error log, bisect log)
  
▶ ▼ ✨ AI Jobs (8)
ID Workflow Result Correct Bug Created Started Finished Revision
3fa410bd assessment-security 💥 KASAN: slab-use-after-free Read in chrdev_open 2026/09/04 02:19 2026/09/04 02:19 2026/09/04 02:36 d2e5fb95
9311d5ad assessment-security 💥 KASAN: slab-use-after-free Read in chrdev_open 2026/08/05 00:01 2026/08/05 00:01 2026/08/05 00:01 d4abbeac
56cdf76f assessment-security 💥 KASAN: slab-use-after-free Read in chrdev_open 2026/07/05 02:21 2026/07/05 02:21 2026/07/05 02:36 93f57954
ccee8fd0 assessment-security 💥 KASAN: slab-use-after-free Read in chrdev_open 2026/06/18 02:07 2026/06/18 02:07 2026/06/18 02:30 b62b3ded
ff4a2878 assessment-security 💥 KASAN: slab-use-after-free Read in chrdev_open 2026/06/09 22:14 2026/06/09 22:14 2026/06/09 22:32 c36c07f6
7899f1e6 assessment-security 💥 KASAN: slab-use-after-free Read in chrdev_open 2026/06/02 23:57 2026/06/02 23:57 2026/06/03 00:19 62fe1528
8fb74f16 assessment-security 💥 KASAN: slab-use-after-free Read in chrdev_open 2026/05/31 17:59 2026/05/31 17:59 2026/05/31 18:24 6b4a8443
93c15a6a assessment-security 💥 KASAN: slab-use-after-free Read in chrdev_open 2026/05/15 06:02 2026/05/15 06:02 2026/05/15 06:03 6ccb967e
▶ ▼ Discussions (2)
Title Replies (including bot) Last reply
[syzbot] [ntfs3?] KASAN: slab-use-after-free Read in chrdev_open 16 (37) 2024/08/23 16:04
[PATCH] fs/ntfs3: dealing with situations where dir_search_u may return null 1 (1) 2024/06/02 09:56
▶ ▼ Similar bugs (4)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-4.19 KASAN: use-after-free Read in chrdev_open 19 syz, C error 14 1499d 2065d 0/1 upstream: reported C repro on 2021/02/11 04:55
android-54 general protection fault in chrdev_open 2 syz, C 1 1583d 1583d 0/2 auto-obsoleted due to no activity on 2023/04/22 08:07
linux-4.14 KASAN: use-after-free Read in chrdev_open 19 syz, C error 4 1500d 2073d 0/1 upstream: reported C repro on 2021/02/03 08:18
android-5-10 general protection fault in chrdev_open 2 syz, C error 1 1584d 1583d 2/2 fixed on 2023/08/02 14:36
▶ ▼ Last patch testing requests (27)
Created Duration User Patch Repo Result
2026/09/23 20:32 24m retest repro upstream no crash job log log
2026/06/30 21:13 18m retest repro upstream log
2026/04/18 13:54 24m retest repro upstream report log
2026/02/07 09:29 16m retest repro upstream report log
2025/11/29 01:16 44m retest repro upstream report log
2025/09/17 22:25 26m retest repro upstream report log
2025/07/04 19:22 12m retest repro upstream report log
2024/08/23 16:04 14m almaz.alexandrovich@paragon-software.com https://github.com/Paragon-Software-Group/linux-ntfs3.git master report log
2024/08/15 08:58 35m almaz.alexandrovich@paragon-software.com upstream report log
2024/06/17 10:30 1h06m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 83a7eefedc9b report log
2024/06/16 11:15 53m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 83a7eefedc9b error
2024/06/16 06:33 51m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 83a7eefedc9b error
2024/06/15 10:40 1h07m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 83a7eefedc9b report log
2024/06/15 06:48 51m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 83a7eefedc9b report log
2024/06/15 00:04 1h06m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 83a7eefedc9b error
2024/06/14 12:48 43m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 83a7eefedc9b error
2024/06/02 09:22 19m eadavis@qq.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git e33c4963bf53 OK log
2024/05/29 11:49 11m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master report log
2024/05/28 22:58 11m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master report log
2024/05/28 11:08 11m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master report log
2024/05/27 23:57 24m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master report log
2024/05/27 11:30 16m almaz.alexandrovich@paragon-software.com upstream report log
2024/05/10 02:36 12m retest repro upstream report log
2024/04/27 10:44 10m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git e33c4963bf53 report log
2024/04/27 09:18 11m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git e33c4963bf53 report log
2024/04/27 06:29 11m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git e33c4963bf53 report log
2024/04/27 02:06 12m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git e33c4963bf53 report log
▶ ▼ Fix bisection attempts (9)
Created Duration User Patch Repo Result
2025/04/25 08:20 7m bisect fix upstream error job log
2025/03/21 07:10 2h17m bisect fix upstream OK (0) job log log
2025/02/18 00:57 1h30m bisect fix upstream OK (0) job log log
2025/01/17 18:50 2h33m bisect fix upstream OK (0) job log log
2024/12/06 14:09 1h42m bisect fix upstream OK (0) job log log
2024/10/23 22:55 1h30m bisect fix upstream OK (0) job log log
2024/09/21 06:52 2h12m bisect fix upstream OK (0) job log log
2024/08/12 17:39 1h23m bisect fix upstream OK (0) job log log
2024/07/01 06:35 1h23m bisect fix upstream OK (0) job log log

Sample crash report:
==================================================================
BUG: KASAN: slab-use-after-free in __list_add_valid_or_report+0x4c/0xf0 lib/list_debug.c:29
Read of size 8 at addr ffff8880641b32b0 by task syz.3.1532/19607

CPU: 1 UID: 0 PID: 19607 Comm: syz.3.1532 Not tainted 6.11.0-rc4-syzkaller-00019-gb311c1b497e5 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/06/2024
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:93 [inline]
 dump_stack_lvl+0x241/0x360 lib/dump_stack.c:119
 print_address_description mm/kasan/report.c:377 [inline]
 print_report+0x169/0x550 mm/kasan/report.c:488
 kasan_report+0x143/0x180 mm/kasan/report.c:601
 __list_add_valid_or_report+0x4c/0xf0 lib/list_debug.c:29
 __list_add_valid include/linux/list.h:88 [inline]
 __list_add include/linux/list.h:150 [inline]
 list_add include/linux/list.h:169 [inline]
 chrdev_open+0x2a9/0x630 fs/char_dev.c:396
 do_dentry_open+0x970/0x1440 fs/open.c:959
 vfs_open+0x3e/0x330 fs/open.c:1089
 do_open fs/namei.c:3727 [inline]
 path_openat+0x2b3e/0x3470 fs/namei.c:3886
 do_filp_open+0x235/0x490 fs/namei.c:3913
 do_sys_openat2+0x13e/0x1d0 fs/open.c:1416
 do_sys_open fs/open.c:1431 [inline]
 __do_sys_openat fs/open.c:1447 [inline]
 __se_sys_openat fs/open.c:1442 [inline]
 __x64_sys_openat+0x247/0x2a0 fs/open.c:1442
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fe8c0779e79
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:00007fe8c14c0038 EFLAGS: 00000246 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 00007fe8c0915f80 RCX: 00007fe8c0779e79
RDX: 0000000000000040 RSI: 0000000020000080 RDI: ffffffffffffff9c
RBP: 00007fe8c07e7916 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 00007fe8c0915f80 R15: 00007ffda76216e8
 </TASK>

Allocated by task 18054:
 kasan_save_stack mm/kasan/common.c:47 [inline]
 kasan_save_track+0x3f/0x80 mm/kasan/common.c:68
 unpoison_slab_object mm/kasan/common.c:312 [inline]
 __kasan_slab_alloc+0x66/0x80 mm/kasan/common.c:338
 kasan_slab_alloc include/linux/kasan.h:201 [inline]
 slab_post_alloc_hook mm/slub.c:3988 [inline]
 slab_alloc_node mm/slub.c:4037 [inline]
 kmem_cache_alloc_lru_noprof+0x139/0x2b0 mm/slub.c:4056
 ntfs_alloc_inode+0x28/0x80 fs/ntfs3/super.c:559
 alloc_inode fs/inode.c:263 [inline]
 new_inode_pseudo fs/inode.c:1073 [inline]
 new_inode+0x6e/0x310 fs/inode.c:1092
 ntfs_new_inode+0x45/0x100 fs/ntfs3/fsntfs.c:1688
 ntfs_create_inode+0x681/0x3880 fs/ntfs3/inode.c:1345
 ntfs_mknod+0x3c/0x50 fs/ntfs3/namei.c:120
 vfs_mknod+0x36d/0x3b0 fs/namei.c:4088
 do_mknodat+0x3ec/0x5b0
 __do_sys_mknodat fs/namei.c:4166 [inline]
 __se_sys_mknodat fs/namei.c:4163 [inline]
 __x64_sys_mknodat+0xa7/0xc0 fs/namei.c:4163
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

Freed by task 17826:
 kasan_save_stack mm/kasan/common.c:47 [inline]
 kasan_save_track+0x3f/0x80 mm/kasan/common.c:68
 kasan_save_free_info+0x40/0x50 mm/kasan/generic.c:579
 poison_slab_object+0xe0/0x150 mm/kasan/common.c:240
 __kasan_slab_free+0x37/0x60 mm/kasan/common.c:256
 kasan_slab_free include/linux/kasan.h:184 [inline]
 slab_free_hook mm/slub.c:2252 [inline]
 slab_free mm/slub.c:4473 [inline]
 kmem_cache_free+0x145/0x350 mm/slub.c:4548
 rcu_do_batch kernel/rcu/tree.c:2569 [inline]
 rcu_core+0xafd/0x1830 kernel/rcu/tree.c:2843
 handle_softirqs+0x2c4/0x970 kernel/softirq.c:554
 __do_softirq kernel/softirq.c:588 [inline]
 invoke_softirq kernel/softirq.c:428 [inline]
 __irq_exit_rcu+0xf4/0x1c0 kernel/softirq.c:637
 irq_exit_rcu+0x9/0x30 kernel/softirq.c:649
 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1043 [inline]
 sysvec_apic_timer_interrupt+0xa6/0xc0 arch/x86/kernel/apic/apic.c:1043
 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:702

Last potentially related work creation:
 kasan_save_stack+0x3f/0x60 mm/kasan/common.c:47
 __kasan_record_aux_stack+0xac/0xc0 mm/kasan/generic.c:541
 __call_rcu_common kernel/rcu/tree.c:3106 [inline]
 call_rcu+0x167/0xa70 kernel/rcu/tree.c:3210
 destroy_inode fs/inode.c:318 [inline]
 evict+0x88b/0x950 fs/inode.c:729
 __dentry_kill+0x20d/0x630 fs/dcache.c:610
 shrink_kill+0xa9/0x2c0 fs/dcache.c:1055
 shrink_dentry_list+0x2c0/0x5b0 fs/dcache.c:1082
 shrink_dcache_parent+0xcb/0x3b0
 do_one_tree+0x23/0xe0 fs/dcache.c:1545
 shrink_dcache_for_umount+0xb4/0x180 fs/dcache.c:1562
 generic_shutdown_super+0x6a/0x2d0 fs/super.c:620
 kill_block_super+0x44/0x90 fs/super.c:1696
 ntfs3_kill_sb+0x44/0x1b0 fs/ntfs3/super.c:1780
 deactivate_locked_super+0xc4/0x130 fs/super.c:473
 cleanup_mnt+0x41f/0x4b0 fs/namespace.c:1373
 task_work_run+0x24f/0x310 kernel/task_work.c:228
 resume_user_mode_work include/linux/resume_user_mode.h:50 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:114 [inline]
 exit_to_user_mode_prepare include/linux/entry-common.h:328 [inline]
 __syscall_exit_to_user_mode_work kernel/entry/common.c:207 [inline]
 syscall_exit_to_user_mode+0x168/0x370 kernel/entry/common.c:218
 do_syscall_64+0x100/0x230 arch/x86/entry/common.c:89
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

The buggy address belongs to the object at ffff8880641b2c10
 which belongs to the cache ntfs_inode_cache of size 1752
The buggy address is located 1696 bytes inside of
 freed 1752-byte region [ffff8880641b2c10, ffff8880641b32e8)

The buggy address belongs to the physical page:
page: refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff8880641b7580 pfn:0x641b0
head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
memcg:ffff8880222e7101
flags: 0xfff00000000040(head|node=0|zone=1|lastcpupid=0x7ff)
page_type: 0xfdffffff(slab)
raw: 00fff00000000040 ffff888019bdc640 ffffea0001908800 0000000000000002
raw: ffff8880641b7580 0000000000110000 00000001fdffffff ffff8880222e7101
head: 00fff00000000040 ffff888019bdc640 ffffea0001908800 0000000000000002
head: ffff8880641b7580 0000000000110000 00000001fdffffff ffff8880222e7101
head: 00fff00000000003 ffffea0001906c01 ffffffffffffffff 0000000000000000
head: 0000000000000008 0000000000000000 00000000ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 3, migratetype Reclaimable, gfp_mask 0x1d2050(__GFP_IO|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC|__GFP_HARDWALL|__GFP_RECLAIMABLE), pid 7346, tgid 7344 (syz.2.204), ts 200885828157, free_ts 200635828994
 set_page_owner include/linux/page_owner.h:32 [inline]
 post_alloc_hook+0x1f3/0x230 mm/page_alloc.c:1493
 prep_new_page mm/page_alloc.c:1501 [inline]
 get_page_from_freelist+0x2e4c/0x2f10 mm/page_alloc.c:3439
 __alloc_pages_noprof+0x256/0x6c0 mm/page_alloc.c:4695
 __alloc_pages_node_noprof include/linux/gfp.h:269 [inline]
 alloc_pages_node_noprof include/linux/gfp.h:296 [inline]
 alloc_slab_page+0x5f/0x120 mm/slub.c:2321
 allocate_slab+0x5a/0x2f0 mm/slub.c:2484
 new_slab mm/slub.c:2537 [inline]
 ___slab_alloc+0xcd1/0x14b0 mm/slub.c:3723
 __slab_alloc+0x58/0xa0 mm/slub.c:3813
 __slab_alloc_node mm/slub.c:3866 [inline]
 slab_alloc_node mm/slub.c:4025 [inline]
 kmem_cache_alloc_lru_noprof+0x1c5/0x2b0 mm/slub.c:4056
 ntfs_alloc_inode+0x28/0x80 fs/ntfs3/super.c:559
 alloc_inode fs/inode.c:263 [inline]
 iget5_locked+0xa3/0x250 fs/inode.c:1294
 ntfs_iget5+0xc7/0x3bb0 fs/ntfs3/inode.c:530
 dir_search_u+0x2fe/0x3a0 fs/ntfs3/dir.c:264
 ntfs_extend_init+0x198/0x530 fs/ntfs3/fsntfs.c:239
 ntfs_fill_super+0x4175/0x4730 fs/ntfs3/super.c:1519
 get_tree_bdev+0x3f7/0x570 fs/super.c:1635
 vfs_get_tree+0x90/0x2a0 fs/super.c:1800
page last free pid 7346 tgid 7344 stack trace:
 reset_page_owner include/linux/page_owner.h:25 [inline]
 free_pages_prepare mm/page_alloc.c:1094 [inline]
 free_unref_page+0xd19/0xea0 mm/page_alloc.c:2612
 __slab_free+0x31b/0x3d0 mm/slub.c:4384
 qlink_free mm/kasan/quarantine.c:163 [inline]
 qlist_free_all+0x9e/0x140 mm/kasan/quarantine.c:179
 kasan_quarantine_reduce+0x14f/0x170 mm/kasan/quarantine.c:286
 __kasan_slab_alloc+0x23/0x80 mm/kasan/common.c:322
 kasan_slab_alloc include/linux/kasan.h:201 [inline]
 slab_post_alloc_hook mm/slub.c:3988 [inline]
 slab_alloc_node mm/slub.c:4037 [inline]
 __do_kmalloc_node mm/slub.c:4157 [inline]
 __kmalloc_noprof+0x1a6/0x400 mm/slub.c:4170
 kmalloc_noprof include/linux/slab.h:685 [inline]
 kmalloc_array_noprof include/linux/slab.h:726 [inline]
 security_inode_init_security+0x126/0x440 security/security.c:1720
 shmem_mknod+0xc5/0x1e0 mm/shmem.c:3433
 shmem_mkdir+0x33/0x70 mm/shmem.c:3487
 vfs_mkdir+0x2f9/0x4f0 fs/namei.c:4210
 do_mkdirat+0x264/0x3a0 fs/namei.c:4233
 __do_sys_mkdirat fs/namei.c:4248 [inline]
 __se_sys_mkdirat fs/namei.c:4246 [inline]
 __x64_sys_mkdirat+0x87/0xa0 fs/namei.c:4246
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

Memory state around the buggy address:
 ffff8880641b3180: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
 ffff8880641b3200: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
>ffff8880641b3280: fb fb fb fb fb fb fb fb fb fb fb fb fb fc fc fc
                                     ^
 ffff8880641b3300: fc fc fc fc fc fc fc fc fc fc fc fc fc fa fb fb
 ffff8880641b3380: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================

Crashes (10):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/08/21 23:11 upstream b311c1b497e5 db5852f9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs KASAN: slab-use-after-free Read in chrdev_open
2024/08/21 23:11 upstream b311c1b497e5 db5852f9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs KASAN: slab-use-after-free Read in chrdev_open
2024/08/21 23:10 upstream b311c1b497e5 db5852f9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs KASAN: slab-use-after-free Read in chrdev_open
2024/08/21 23:10 upstream b311c1b497e5 db5852f9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs KASAN: slab-use-after-free Read in chrdev_open
2024/08/21 23:09 upstream b311c1b497e5 db5852f9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs KASAN: slab-use-after-free Read in chrdev_open
2024/08/21 23:09 upstream b311c1b497e5 db5852f9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs KASAN: slab-use-after-free Read in chrdev_open
2024/08/21 23:08 upstream b311c1b497e5 db5852f9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs KASAN: slab-use-after-free Read in chrdev_open
2024/08/21 23:05 upstream b311c1b497e5 db5852f9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs KASAN: slab-use-after-free Read in chrdev_open
2024/04/26 01:42 upstream e33c4963bf53 8bdc0f22 .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs KASAN: slab-use-after-free Read in chrdev_open
2024/04/26 01:01 upstream e33c4963bf53 8bdc0f22 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs KASAN: slab-use-after-free Read in chrdev_open
* Struck through repros no longer work on HEAD.