CIFS mount error: No usable UNC path provided in device string! CIFS: VFS: CIFS mount error: No usable UNC path provided in device string! ================================================================== BUG: KASAN: slab-use-after-free in __list_add_valid_or_report+0x105/0x130 lib/list_debug.c:29 Read of size 8 at addr ffff888000a7e440 by task syz.3.6282/30713 CPU: 3 UID: 0 PID: 30713 Comm: syz.3.6282 Tainted: G L syzkaller #0 PREEMPT(full) Tainted: [L]=SOFTLOCKUP Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 Call Trace: __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0x100/0x190 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:378 [inline] print_report+0x156/0x4c9 mm/kasan/report.c:482 kasan_report+0xdf/0x1e0 mm/kasan/report.c:595 __list_add_valid_or_report+0x105/0x130 lib/list_debug.c:29 __list_add_valid include/linux/list.h:96 [inline] __list_add include/linux/list.h:158 [inline] list_add include/linux/list.h:177 [inline] clone_mnt+0x633/0x930 fs/namespace.c:1275 copy_tree+0xfc/0xbf0 fs/namespace.c:2159 copy_mnt_ns+0x2bd/0xc30 fs/namespace.c:4246 create_new_namespaces+0xd3/0xac0 kernel/nsproxy.c:98 copy_namespaces+0x468/0x5e0 kernel/nsproxy.c:195 copy_process+0x3226/0x7a10 kernel/fork.c:2226 kernel_clone+0xfc/0x9a0 kernel/fork.c:2654 __do_compat_sys_ia32_clone+0xd4/0x120 arch/x86/kernel/sys_ia32.c:254 do_syscall_32_irqs_on arch/x86/entry/syscall_32.c:83 [inline] __do_fast_syscall_32+0xe3/0x8c0 arch/x86/entry/syscall_32.c:307 do_fast_syscall_32+0x32/0x70 arch/x86/entry/syscall_32.c:332 entry_SYSENTER_compat_after_hwframe+0x84/0x8e RIP: 0023:0xf7ff2f6c Code: d2 74 05 c1 e8 0c 89 02 8b 5d fc 31 c0 c9 c3 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 0f 1f 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 58 b8 77 00 00 00 cd 80 0f 0b 8d b6 00 00 00 00 b8 ad RSP: 002b:00000000f54b64bc EFLAGS: 00000246 ORIG_RAX: 0000000000000078 RAX: ffffffffffffffda RBX: 0000000000020000 RCX: 00000000800003f0 RDX: 0000000080000300 RSI: 0000000080000100 RDI: 0000000080000180 RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000292 R12: 0000000000000000 R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 Allocated by task 30485: kasan_save_stack+0x30/0x50 mm/kasan/common.c:57 kasan_save_track+0x14/0x30 mm/kasan/common.c:78 unpoison_slab_object mm/kasan/common.c:340 [inline] __kasan_slab_alloc+0x89/0x90 mm/kasan/common.c:366 kasan_slab_alloc include/linux/kasan.h:253 [inline] slab_post_alloc_hook mm/slub.c:4501 [inline] slab_alloc_node mm/slub.c:4830 [inline] kmem_cache_alloc_noprof+0x241/0x6e0 mm/slub.c:4837 alloc_vfsmnt+0x23/0x6a0 fs/namespace.c:287 clone_mnt+0x4b/0x930 fs/namespace.c:1246 create_new_namespace fs/namespace.c:3098 [inline] open_new_namespace fs/namespace.c:3168 [inline] vfs_open_tree+0xb02/0x1500 fs/namespace.c:3217 __do_sys_open_tree fs/namespace.c:3227 [inline] __se_sys_open_tree fs/namespace.c:3225 [inline] __ia32_sys_open_tree+0xa3/0x150 fs/namespace.c:3225 do_syscall_32_irqs_on arch/x86/entry/syscall_32.c:83 [inline] __do_fast_syscall_32+0xe3/0x8c0 arch/x86/entry/syscall_32.c:307 do_fast_syscall_32+0x32/0x70 arch/x86/entry/syscall_32.c:332 entry_SYSENTER_compat_after_hwframe+0x84/0x8e Freed by task 0: kasan_save_stack+0x30/0x50 mm/kasan/common.c:57 kasan_save_track+0x14/0x30 mm/kasan/common.c:78 kasan_save_free_info+0x3b/0x70 mm/kasan/generic.c:584 poison_slab_object mm/kasan/common.c:253 [inline] __kasan_slab_free+0x5f/0x80 mm/kasan/common.c:285 kasan_slab_free include/linux/kasan.h:235 [inline] slab_free_hook mm/slub.c:2687 [inline] slab_free mm/slub.c:6124 [inline] kmem_cache_free+0x124/0x6a0 mm/slub.c:6254 rcu_do_batch kernel/rcu/tree.c:2617 [inline] rcu_core+0x5a2/0x10d0 kernel/rcu/tree.c:2869 handle_softirqs+0x1eb/0x9e0 kernel/softirq.c:622 __do_softirq kernel/softirq.c:656 [inline] invoke_softirq kernel/softirq.c:496 [inline] __irq_exit_rcu+0xef/0x150 kernel/softirq.c:723 irq_exit_rcu+0x9/0x30 kernel/softirq.c:739 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1056 [inline] sysvec_apic_timer_interrupt+0xa3/0xc0 arch/x86/kernel/apic/apic.c:1056 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:697 Last potentially related work creation: kasan_save_stack+0x30/0x50 mm/kasan/common.c:57 kasan_record_aux_stack+0xa7/0xc0 mm/kasan/generic.c:556 __call_rcu_common.constprop.0+0xa5/0x9b0 kernel/rcu/tree.c:3131 task_work_run+0x150/0x240 kernel/task_work.c:233 resume_user_mode_work include/linux/resume_user_mode.h:50 [inline] __exit_to_user_mode_loop kernel/entry/common.c:67 [inline] exit_to_user_mode_loop+0x100/0x4a0 kernel/entry/common.c:98 __exit_to_user_mode_prepare include/linux/irq-entry-common.h:226 [inline] syscall_exit_to_user_mode_prepare include/linux/irq-entry-common.h:256 [inline] syscall_exit_to_user_mode include/linux/entry-common.h:325 [inline] __do_fast_syscall_32+0x578/0x8c0 arch/x86/entry/syscall_32.c:310 do_fast_syscall_32+0x32/0x70 arch/x86/entry/syscall_32.c:332 entry_SYSENTER_compat_after_hwframe+0x84/0x8e Second to last potentially related work creation: kasan_save_stack+0x30/0x50 mm/kasan/common.c:57 kasan_record_aux_stack+0xa7/0xc0 mm/kasan/generic.c:556 task_work_add+0x28b/0x3b0 kernel/task_work.c:70 mntput_no_expire_slowpath+0x3da/0xb00 fs/namespace.c:1379 mntput_no_expire+0x1fd/0x220 fs/namespace.c:1406 mntput+0x6b/0xa0 fs/namespace.c:1416 create_new_namespace fs/namespace.c:3082 [inline] open_new_namespace fs/namespace.c:3168 [inline] vfs_open_tree+0x1235/0x1500 fs/namespace.c:3217 __do_sys_open_tree fs/namespace.c:3227 [inline] __se_sys_open_tree fs/namespace.c:3225 [inline] __ia32_sys_open_tree+0xa3/0x150 fs/namespace.c:3225 do_syscall_32_irqs_on arch/x86/entry/syscall_32.c:83 [inline] __do_fast_syscall_32+0xe3/0x8c0 arch/x86/entry/syscall_32.c:307 do_fast_syscall_32+0x32/0x70 arch/x86/entry/syscall_32.c:332 entry_SYSENTER_compat_after_hwframe+0x84/0x8e The buggy address belongs to the object at ffff888000a7e380 which belongs to the cache mnt_cache of size 352 The buggy address is located 192 bytes inside of freed 352-byte region [ffff888000a7e380, ffff888000a7e4e0) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0xffff888000a7efc0 pfn:0xa7e head: order:1 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 memcg:ffff888000a7e171 flags: 0x7ff00000000240(workingset|head|node=0|zone=0|lastcpupid=0x7ff) page_type: f5(slab) raw: 007ff00000000240 ffff88804049b180 ffffea0000a9c210 ffffea000075b510 raw: ffff888000a7efc0 000001c00012000a 00000000f5000000 ffff888000a7e171 head: 007ff00000000240 ffff88804049b180 ffffea0000a9c210 ffffea000075b510 head: ffff888000a7efc0 000001c00012000a 00000000f5000000 ffff888000a7e171 head: 007ff00000000001 ffffea0000029f81 00000000ffffffff 00000000ffffffff head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000002 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 1, migratetype Unmovable, gfp_mask 0xd20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 11181, tgid 11180 (syz.1.1750), ts 189478460889, free_ts 22855337070 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x153/0x170 mm/page_alloc.c:1889 prep_new_page mm/page_alloc.c:1897 [inline] get_page_from_freelist+0x111d/0x3140 mm/page_alloc.c:3962 __alloc_frozen_pages_noprof+0x27c/0x2ba0 mm/page_alloc.c:5250 alloc_slab_page mm/slub.c:3255 [inline] allocate_slab mm/slub.c:3444 [inline] new_slab+0xa6/0x6d0 mm/slub.c:3502 refill_objects+0x26b/0x400 mm/slub.c:7134 refill_sheaf mm/slub.c:2804 [inline] alloc_full_sheaf mm/slub.c:2825 [inline] __pcs_replace_empty_main+0x19f/0x600 mm/slub.c:4588 alloc_from_pcs mm/slub.c:4681 [inline] slab_alloc_node mm/slub.c:4815 [inline] kmem_cache_alloc_noprof+0x480/0x6e0 mm/slub.c:4837 alloc_vfsmnt+0x23/0x6a0 fs/namespace.c:287 vfs_create_mount fs/namespace.c:1178 [inline] vfs_create_mount fs/namespace.c:1171 [inline] fc_mount fs/namespace.c:1196 [inline] fc_mount fs/namespace.c:1191 [inline] do_new_mount_fc fs/namespace.c:3760 [inline] do_new_mount fs/namespace.c:3836 [inline] path_mount+0x1e6b/0x23d0 fs/namespace.c:4146 do_mount fs/namespace.c:4159 [inline] __do_sys_mount fs/namespace.c:4348 [inline] __se_sys_mount fs/namespace.c:4325 [inline] __ia32_sys_mount+0x292/0x310 fs/namespace.c:4325 do_syscall_32_irqs_on arch/x86/entry/syscall_32.c:83 [inline] __do_fast_syscall_32+0xe3/0x8c0 arch/x86/entry/syscall_32.c:307 do_fast_syscall_32+0x32/0x70 arch/x86/entry/syscall_32.c:332 entry_SYSENTER_compat_after_hwframe+0x84/0x8e page last free pid 60 tgid 60 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] __free_pages_prepare mm/page_alloc.c:1433 [inline] __free_frozen_pages+0x7e1/0x10d0 mm/page_alloc.c:2978 kasan_depopulate_vmalloc_pte+0x5d/0x80 mm/kasan/shadow.c:484 apply_to_pte_range mm/memory.c:3243 [inline] apply_to_pmd_range mm/memory.c:3287 [inline] apply_to_pud_range mm/memory.c:3323 [inline] apply_to_p4d_range mm/memory.c:3359 [inline] __apply_to_page_range+0xb1d/0x1520 mm/memory.c:3395 __kasan_release_vmalloc+0xd7/0xe0 mm/kasan/shadow.c:602 kasan_release_vmalloc include/linux/kasan.h:593 [inline] kasan_release_vmalloc_node mm/vmalloc.c:2290 [inline] purge_vmap_node+0x210/0xb40 mm/vmalloc.c:2312 __purge_vmap_area_lazy+0x935/0xc20 mm/vmalloc.c:2402 drain_vmap_area_work+0x27/0x40 mm/vmalloc.c:2436 process_one_work+0x9d7/0x1920 kernel/workqueue.c:3275 process_scheduled_works kernel/workqueue.c:3358 [inline] worker_thread+0x5da/0xe40 kernel/workqueue.c:3439 kthread+0x370/0x450 kernel/kthread.c:467 ret_from_fork+0x754/0xd80 arch/x86/kernel/process.c:158 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 Memory state around the buggy address: ffff888000a7e300: fb fb fb fb fc fc fc fc fc fc fc fc fc fc fc fc ffff888000a7e380: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb >ffff888000a7e400: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff888000a7e480: fb fb fb fb fb fb fb fb fb fb fb fb fc fc fc fc ffff888000a7e500: fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb fb ================================================================== ---------------- Code disassembly (best guess): 0: d2 74 05 c1 shlb %cl,-0x3f(%rbp,%rax,1) 4: e8 0c 89 02 8b call 0x8b028915 9: 5d pop %rbp a: fc cld b: 31 c0 xor %eax,%eax d: c9 leave e: c3 ret f: 90 nop 10: 90 nop 11: 90 nop 12: 90 nop 13: 90 nop 14: 90 nop 15: 90 nop 16: 90 nop 17: 90 nop 18: 90 nop 19: 90 nop 1a: 90 nop 1b: 90 nop 1c: 90 nop 1d: 90 nop 1e: 0f 1f 00 nopl (%rax) 21: 51 push %rcx 22: 52 push %rdx 23: 55 push %rbp 24: 89 e5 mov %esp,%ebp 26: 0f 34 sysenter 28: cd 80 int $0x80 * 2a: 5d pop %rbp <-- trapping instruction 2b: 5a pop %rdx 2c: 59 pop %rcx 2d: c3 ret 2e: 58 pop %rax 2f: b8 77 00 00 00 mov $0x77,%eax 34: cd 80 int $0x80 36: 0f 0b ud2 38: 8d b6 00 00 00 00 lea 0x0(%rsi),%esi 3e: b8 .byte 0xb8 3f: ad lods %ds:(%rsi),%eax