================================================================== BUG: KASAN: slab-out-of-bounds in ntfs_list_ea fs/ntfs3/xattr.c:230 [inline] BUG: KASAN: slab-out-of-bounds in ntfs_listxattr+0x354/0x50c fs/ntfs3/xattr.c:751 Read of size 48 at addr ffff0000c3ba4530 by task syz-executor.2/18991 CPU: 1 PID: 18991 Comm: syz-executor.2 Not tainted 6.1.62-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/09/2023 Call trace: dump_backtrace+0x1c8/0x1f4 arch/arm64/kernel/stacktrace.c:158 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:165 __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x108/0x170 lib/dump_stack.c:106 print_address_description mm/kasan/report.c:284 [inline] print_report+0x174/0x4c0 mm/kasan/report.c:395 kasan_report+0xd4/0x130 mm/kasan/report.c:495 kasan_check_range+0x264/0x2a4 mm/kasan/generic.c:189 memcpy+0x48/0x90 mm/kasan/shadow.c:65 ntfs_list_ea fs/ntfs3/xattr.c:230 [inline] ntfs_listxattr+0x354/0x50c fs/ntfs3/xattr.c:751 vfs_listxattr fs/xattr.c:457 [inline] listxattr+0x29c/0x3cc fs/xattr.c:804 path_listxattr fs/xattr.c:828 [inline] __do_sys_listxattr fs/xattr.c:840 [inline] __se_sys_listxattr fs/xattr.c:837 [inline] __arm64_sys_listxattr+0x13c/0x21c fs/xattr.c:837 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2c0 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142 do_el0_svc+0x64/0x218 arch/arm64/kernel/syscall.c:206 el0_svc+0x58/0x168 arch/arm64/kernel/entry-common.c:637 el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655 el0t_64_sync+0x18c/0x190 arch/arm64/kernel/entry.S:585 Allocated by task 18991: kasan_save_stack mm/kasan/common.c:45 [inline] kasan_set_track+0x4c/0x80 mm/kasan/common.c:52 kasan_save_alloc_info+0x24/0x30 mm/kasan/generic.c:505 ____kasan_kmalloc mm/kasan/common.c:374 [inline] __kasan_kmalloc+0xac/0xc4 mm/kasan/common.c:383 kasan_kmalloc include/linux/kasan.h:211 [inline] __do_kmalloc_node mm/slab_common.c:955 [inline] __kmalloc+0xd8/0x1c4 mm/slab_common.c:968 kmalloc include/linux/slab.h:558 [inline] ntfs_read_ea+0x3c0/0x818 fs/ntfs3/xattr.c:117 ntfs_list_ea fs/ntfs3/xattr.c:202 [inline] ntfs_listxattr+0x14c/0x50c fs/ntfs3/xattr.c:751 vfs_listxattr fs/xattr.c:457 [inline] listxattr+0x29c/0x3cc fs/xattr.c:804 path_listxattr fs/xattr.c:828 [inline] __do_sys_listxattr fs/xattr.c:840 [inline] __se_sys_listxattr fs/xattr.c:837 [inline] __arm64_sys_listxattr+0x13c/0x21c fs/xattr.c:837 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2c0 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142 do_el0_svc+0x64/0x218 arch/arm64/kernel/syscall.c:206 el0_svc+0x58/0x168 arch/arm64/kernel/entry-common.c:637 el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655 el0t_64_sync+0x18c/0x190 arch/arm64/kernel/entry.S:585 Last potentially related work creation: kasan_save_stack+0x40/0x70 mm/kasan/common.c:45 __kasan_record_aux_stack+0xcc/0xe8 mm/kasan/generic.c:486 kasan_record_aux_stack_noalloc+0x14/0x20 mm/kasan/generic.c:496 kvfree_call_rcu+0xb4/0x714 kernel/rcu/tree.c:3355 kernfs_unlink_open_file+0x398/0x448 fs/kernfs/file.c:629 kernfs_fop_release+0x130/0x198 fs/kernfs/file.c:801 __fput+0x30c/0x7bc fs/file_table.c:320 ____fput+0x20/0x30 fs/file_table.c:348 task_work_run+0x240/0x2f0 kernel/task_work.c:179 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline] do_notify_resume+0x2148/0x3474 arch/arm64/kernel/signal.c:1132 prepare_exit_to_user_mode arch/arm64/kernel/entry-common.c:137 [inline] exit_to_user_mode arch/arm64/kernel/entry-common.c:142 [inline] el0_svc+0x9c/0x168 arch/arm64/kernel/entry-common.c:638 el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655 el0t_64_sync+0x18c/0x190 arch/arm64/kernel/entry.S:585 Second to last potentially related work creation: kasan_save_stack+0x40/0x70 mm/kasan/common.c:45 __kasan_record_aux_stack+0xcc/0xe8 mm/kasan/generic.c:486 kasan_record_aux_stack_noalloc+0x14/0x20 mm/kasan/generic.c:496 kvfree_call_rcu+0xb4/0x714 kernel/rcu/tree.c:3355 kernfs_unlink_open_file+0x398/0x448 fs/kernfs/file.c:629 kernfs_fop_release+0x130/0x198 fs/kernfs/file.c:801 __fput+0x30c/0x7bc fs/file_table.c:320 ____fput+0x20/0x30 fs/file_table.c:348 task_work_run+0x240/0x2f0 kernel/task_work.c:179 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline] do_notify_resume+0x2148/0x3474 arch/arm64/kernel/signal.c:1132 prepare_exit_to_user_mode arch/arm64/kernel/entry-common.c:137 [inline] exit_to_user_mode arch/arm64/kernel/entry-common.c:142 [inline] el0_svc+0x9c/0x168 arch/arm64/kernel/entry-common.c:638 el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655 el0t_64_sync+0x18c/0x190 arch/arm64/kernel/entry.S:585 The buggy address belongs to the object at ffff0000c3ba4500 which belongs to the cache kmalloc-128 of size 128 The buggy address is located 48 bytes inside of 128-byte region [ffff0000c3ba4500, ffff0000c3ba4580) The buggy address belongs to the physical page: page:00000000a57c5bc9 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x103ba4 flags: 0x5ffc00000000200(slab|node=0|zone=2|lastcpupid=0x7ff) raw: 05ffc00000000200 dead000000000100 dead000000000122 ffff0000c0002300 raw: 0000000000000000 0000000080100010 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff0000c3ba4400: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc ffff0000c3ba4480: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff0000c3ba4500: 00 00 00 00 00 00 00 04 fc fc fc fc fc fc fc fc ^ ffff0000c3ba4580: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff0000c3ba4600: 00 00 00 00 fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================