BTRFS: device fsid 3030b86e-0d5f-4090-902c-6457136cf04d devid 1 transid 7 /dev/loop7 ================================================================== BUG: KASAN: slab-out-of-bounds in strcpy+0x9e/0xb0 lib/string.c:91 Write of size 1 at addr ffff8801ccf8520b by task syz-executor7/10581 CPU: 0 PID: 10581 Comm: syz-executor7 Not tainted 4.9.92-g13b40d3 #12 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 ffff88019b4274a8 ffffffff81d95109 ffffea000733e000 ffff8801ccf8520b 0000000000000001 ffff8801ccf8520b dffffc0000000000 ffff88019b4274e0 ffffffff8153d5d3 ffff8801ccf8520b 0000000000000001 0000000000000001 Call Trace: [] __dump_stack lib/dump_stack.c:15 [inline] [] dump_stack+0xc1/0x128 lib/dump_stack.c:51 [] print_address_description+0x73/0x280 mm/kasan/report.c:256 [] kasan_report_error mm/kasan/report.c:355 [inline] [] kasan_report+0x255/0x380 mm/kasan/report.c:412 [] __asan_report_store1_noabort+0x17/0x20 mm/kasan/report.c:435 [] strcpy+0x9e/0xb0 lib/string.c:91 [] selinux_sb_copy_data+0x2aa/0x390 security/selinux/hooks.c:2695 [] security_sb_copy_data+0x75/0xb0 security/security.c:283 [] parse_security_options+0x36/0x90 fs/btrfs/super.c:1493 [] btrfs_mount+0xa02/0x2c00 fs/btrfs/super.c:1572 [] mount_fs+0x27f/0x350 fs/super.c:1206 [] vfs_kern_mount.part.21+0xd0/0x3e0 fs/namespace.c:991 [] vfs_kern_mount+0x40/0x60 fs/namespace.c:973 [] mount_subvol fs/btrfs/super.c:1395 [inline] [] btrfs_mount+0x2ee/0x2c00 fs/btrfs/super.c:1566 [] mount_fs+0x27f/0x350 fs/super.c:1206 [] vfs_kern_mount.part.21+0xd0/0x3e0 fs/namespace.c:991 [] vfs_kern_mount fs/namespace.c:2509 [inline] [] do_new_mount fs/namespace.c:2512 [inline] [] do_mount+0x3e1/0x28b0 fs/namespace.c:2834 [] C_SYSC_mount fs/compat.c:810 [inline] [] compat_SyS_mount+0xd0/0x1070 fs/compat.c:775 [] do_syscall_32_irqs_on arch/x86/entry/common.c:325 [inline] [] do_fast_syscall_32+0x2f5/0x870 arch/x86/entry/common.c:387 [] entry_SYSENTER_compat+0x90/0xa2 arch/x86/entry/entry_64_compat.S:137 Allocated by task 10581: save_stack_trace+0x16/0x20 arch/x86/kernel/stacktrace.c:57 save_stack+0x43/0xd0 mm/kasan/kasan.c:505 set_track mm/kasan/kasan.c:517 [inline] kasan_kmalloc+0xad/0xe0 mm/kasan/kasan.c:609 __kmalloc+0x11d/0x310 mm/slub.c:3741 kmalloc include/linux/slab.h:495 [inline] setup_root_args fs/btrfs/super.c:1358 [inline] mount_subvol fs/btrfs/super.c:1389 [inline] btrfs_mount+0x1bd/0x2c00 fs/btrfs/super.c:1566 mount_fs+0x27f/0x350 fs/super.c:1206 vfs_kern_mount.part.21+0xd0/0x3e0 fs/namespace.c:991 vfs_kern_mount fs/namespace.c:2509 [inline] do_new_mount fs/namespace.c:2512 [inline] do_mount+0x3e1/0x28b0 fs/namespace.c:2834 C_SYSC_mount fs/compat.c:810 [inline] compat_SyS_mount+0xd0/0x1070 fs/compat.c:775 do_syscall_32_irqs_on arch/x86/entry/common.c:325 [inline] do_fast_syscall_32+0x2f5/0x870 arch/x86/entry/common.c:387 entry_SYSENTER_compat+0x90/0xa2 arch/x86/entry/entry_64_compat.S:137 Freed by task 9184: save_stack_trace+0x16/0x20 arch/x86/kernel/stacktrace.c:57 save_stack+0x43/0xd0 mm/kasan/kasan.c:505 set_track mm/kasan/kasan.c:517 [inline] kasan_slab_free+0x72/0xc0 mm/kasan/kasan.c:582 slab_free_hook mm/slub.c:1355 [inline] slab_free_freelist_hook mm/slub.c:1377 [inline] slab_free mm/slub.c:2958 [inline] kfree+0x103/0x300 mm/slub.c:3878 snd_seq_oss_readq_delete+0x36/0x50 sound/core/seq/oss/seq_oss_readq.c:78 free_devinfo+0x8b/0xb0 sound/core/seq/oss/seq_oss_init.c:408 port_delete+0xd5/0x110 sound/core/seq/seq_ports.c:273 snd_seq_delete_port+0x1c3/0x200 sound/core/seq/seq_ports.c:303 snd_seq_ioctl_delete_port+0xb4/0x170 sound/core/seq/seq_clientmgr.c:1321 snd_seq_kernel_client_ctl+0x122/0x160 sound/core/seq/seq_clientmgr.c:2363 snd_seq_event_port_detach+0xaf/0x100 sound/core/seq/seq_ports.c:706 delete_port+0x73/0xb0 sound/core/seq/oss/seq_oss_init.c:354 snd_seq_oss_release+0xe4/0x130 sound/core/seq/oss/seq_oss_init.c:433 odev_release+0x52/0x70 sound/core/seq/oss/seq_oss.c:153 __fput+0x28c/0x6e0 fs/file_table.c:208 ____fput+0x15/0x20 fs/file_table.c:244 task_work_run+0x115/0x190 kernel/task_work.c:116 exit_task_work include/linux/task_work.h:21 [inline] do_exit+0x7e7/0x2a40 kernel/exit.c:833 do_group_exit+0x108/0x320 kernel/exit.c:937 get_signal+0x4d4/0x14e0 kernel/signal.c:2317 do_signal+0x87/0x19f0 arch/x86/kernel/signal.c:807 exit_to_usermode_loop+0xe1/0x120 arch/x86/entry/common.c:157 prepare_exit_to_usermode arch/x86/entry/common.c:191 [inline] syscall_return_slowpath arch/x86/entry/common.c:260 [inline] do_syscall_32_irqs_on arch/x86/entry/common.c:331 [inline] do_fast_syscall_32+0x5c1/0x870 arch/x86/entry/common.c:387 entry_SYSENTER_compat+0x90/0xa2 arch/x86/entry/entry_64_compat.S:137 The buggy address belongs to the object at ffff8801ccf84200 which belongs to the cache kmalloc-8192 of size 8192 The buggy address is located 4107 bytes inside of 8192-byte region [ffff8801ccf84200, ffff8801ccf86200) The buggy address belongs to the page: page:ffffea000733e000 count:1 mapcount:0 mapping: (null) index:0x0 compound_mapcount: 0 flags: 0x8000000000004080(slab|head) page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8801ccf85100: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8801ccf85180: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff8801ccf85200: 00 03 fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff8801ccf85280: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8801ccf85300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================