================================================================== BUG: KASAN: slab-out-of-bounds in vsscanf+0x2666/0x2ef0 lib/vsprintf.c:3321 Read of size 1 at addr ffff8880a6423ad7 by task syz-executor.5/16839 CPU: 0 PID: 16839 Comm: syz-executor.5 Not tainted 5.8.0-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x1f0/0x31e lib/dump_stack.c:118 print_address_description+0x66/0x5a0 mm/kasan/report.c:383 __kasan_report mm/kasan/report.c:513 [inline] kasan_report+0x132/0x1d0 mm/kasan/report.c:530 vsscanf+0x2666/0x2ef0 lib/vsprintf.c:3321 sscanf+0x6c/0x90 lib/vsprintf.c:3527 smk_set_cipso+0x374/0x6c0 security/smack/smackfs.c:908 vfs_write+0x2dd/0xc50 fs/read_write.c:576 ksys_write+0x11b/0x220 fs/read_write.c:631 do_syscall_64+0x73/0xe0 arch/x86/entry/common.c:384 entry_SYSCALL_64_after_hwframe+0x44/0xa9 RIP: 0033:0x45cce9 Code: 2d b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 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 0f 83 fb b5 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007f81a7083c78 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 0000000000038600 RCX: 000000000045cce9 RDX: 00000000000000d6 RSI: 00000000200000c0 RDI: 0000000000000004 RBP: 000000000078bf40 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000078bf0c R13: 00007ffdf5560e5f R14: 00007f81a70849c0 R15: 000000000078bf0c Allocated by task 16839: save_stack mm/kasan/common.c:48 [inline] set_track mm/kasan/common.c:56 [inline] __kasan_kmalloc+0x103/0x140 mm/kasan/common.c:494 __do_kmalloc mm/slab.c:3656 [inline] __kmalloc_track_caller+0x249/0x320 mm/slab.c:3671 memdup_user_nul+0x26/0xf0 mm/util.c:259 smk_set_cipso+0xff/0x6c0 security/smack/smackfs.c:859 vfs_write+0x2dd/0xc50 fs/read_write.c:576 ksys_write+0x11b/0x220 fs/read_write.c:631 do_syscall_64+0x73/0xe0 arch/x86/entry/common.c:384 entry_SYSCALL_64_after_hwframe+0x44/0xa9 Freed by task 16230: save_stack mm/kasan/common.c:48 [inline] set_track mm/kasan/common.c:56 [inline] kasan_set_free_info mm/kasan/common.c:316 [inline] __kasan_slab_free+0x114/0x170 mm/kasan/common.c:455 __cache_free mm/slab.c:3426 [inline] kfree+0x10a/0x220 mm/slab.c:3757 smk_fetch security/smack/smack_lsm.c:300 [inline] smack_d_instantiate+0x934/0xce0 security/smack/smack_lsm.c:3431 security_d_instantiate+0xa5/0x100 security/security.c:1957 d_instantiate_new+0x61/0x110 fs/dcache.c:1992 ext4_add_nondir+0x20a/0x270 fs/ext4/namei.c:2584 ext4_symlink+0x8ba/0xef0 fs/ext4/namei.c:3372 vfs_symlink+0x36f/0x520 fs/namei.c:3953 do_symlinkat+0x18b/0x420 fs/namei.c:3980 do_syscall_64+0x73/0xe0 arch/x86/entry/common.c:384 entry_SYSCALL_64_after_hwframe+0x44/0xa9 The buggy address belongs to the object at ffff8880a6423a00 which belongs to the cache kmalloc-256 of size 256 The buggy address is located 215 bytes inside of 256-byte region [ffff8880a6423a00, ffff8880a6423b00) The buggy address belongs to the page: page:ffffea00029908c0 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 flags: 0xfffe0000000200(slab) raw: 00fffe0000000200 ffffea000285af88 ffffea00022255c8 ffff8880aa4008c0 raw: 0000000000000000 ffff8880a6423000 0000000100000008 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880a6423980: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880a6423a00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff8880a6423a80: 00 00 00 00 00 00 00 00 00 00 07 fc fc fc fc fc ^ ffff8880a6423b00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880a6423b80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================