EXT4-fs error (device sda1): ext4_xattr_set_entry:1607: inode #15851: comm syz-executor.5: corrupted xattr entries EXT4-fs error (device sda1): ext4_xattr_set_entry:1607: inode #15839: comm syz-executor.4: corrupted xattr entries ================================================================== BUG: KASAN: use-after-free in ext4_xattr_set_entry+0x2742/0x3810 fs/ext4/xattr.c:1604 Read of size 4 at addr ffff8881c8d82004 by task syz-executor.1/18082 CPU: 0 PID: 18082 Comm: syz-executor.1 Not tainted 4.19.161-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+0x17c/0x22a lib/dump_stack.c:118 print_address_description.cold.6+0x9/0x211 mm/kasan/report.c:256 kasan_report_error mm/kasan/report.c:354 [inline] kasan_report.cold.7+0x242/0x307 mm/kasan/report.c:412 __asan_report_load4_noabort+0x14/0x20 mm/kasan/report.c:432 ext4_xattr_set_entry+0x2742/0x3810 fs/ext4/xattr.c:1604 ext4_xattr_ibody_set+0x70/0x290 fs/ext4/xattr.c:2243 ext4_xattr_set_handle+0x59d/0xc20 fs/ext4/xattr.c:2399 ext4_xattr_set+0x1bc/0x300 fs/ext4/xattr.c:2511 ext4_xattr_trusted_set+0x1e/0x20 fs/ext4/xattr_trusted.c:37 __vfs_setxattr+0xd9/0x140 fs/xattr.c:149 __vfs_setxattr_noperm+0xe9/0x380 fs/xattr.c:180 __vfs_setxattr_locked+0x185/0x200 fs/xattr.c:238 vfs_setxattr+0x101/0x280 fs/xattr.c:255 setxattr+0x1af/0x280 fs/xattr.c:520 path_setxattr+0x144/0x160 fs/xattr.c:539 __do_sys_setxattr fs/xattr.c:554 [inline] __se_sys_setxattr fs/xattr.c:550 [inline] __x64_sys_setxattr+0xbf/0x150 fs/xattr.c:550 do_syscall_64+0xd0/0x4e0 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x45deb9 Code: 0d b4 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 db b3 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007f21323eac78 EFLAGS: 00000246 ORIG_RAX: 00000000000000bc RAX: ffffffffffffffda RBX: 0000000000033980 RCX: 000000000045deb9 RDX: 0000000000000000 RSI: 0000000020000140 RDI: 0000000020000100 RBP: 000000000118c018 R08: 0000000000000001 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000118bfd4 R13: 00007ffe7b868e8f R14: 00007f21323eb9c0 R15: 000000000118bfd4 The buggy address belongs to the page: page:ffffea0007236080 count:0 mapcount:-128 mapping:0000000000000000 index:0x1 flags: 0x17ff00000000000() raw: 017ff00000000000 ffff88823fff9ef8 ffffea00071b2808 0000000000000000 raw: 0000000000000001 0000000000000001 00000000ffffff7f 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8881c8d81f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8881c8d81f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff8881c8d82000: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff8881c8d82080: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff8881c8d82100: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ==================================================================