loop0: detected capacity change from 0 to 32768 ================================================================== BUG: KASAN: slab-out-of-bounds in reiserfs_xattr_get+0xe3/0x580 fs/reiserfs/xattr.c:674 Read of size 8 at addr ffff88807ca06798 by task syz-executor.0/12159 CPU: 0 PID: 12159 Comm: syz-executor.0 Not tainted 6.1.0-rc2-syzkaller-00105-gb229b6ca5abb #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/11/2022 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x1b1/0x28e lib/dump_stack.c:106 print_address_description+0x74/0x340 mm/kasan/report.c:284 print_report+0x107/0x1f0 mm/kasan/report.c:395 kasan_report+0xcd/0x100 mm/kasan/report.c:495 reiserfs_xattr_get+0xe3/0x580 fs/reiserfs/xattr.c:674 reiserfs_get_acl+0x7a/0x650 fs/reiserfs/xattr_acl.c:214 get_acl+0x157/0x260 fs/posix_acl.c:153 check_acl+0x35/0x150 fs/namei.c:306 acl_permission_check fs/namei.c:351 [inline] generic_permission+0x388/0x4e0 fs/namei.c:404 do_inode_permission fs/namei.c:458 [inline] inode_permission+0x22c/0x450 fs/namei.c:525 may_open+0x2a4/0x400 fs/namei.c:3185 do_open fs/namei.c:3555 [inline] path_openat+0x24a2/0x2df0 fs/namei.c:3713 do_filp_open+0x264/0x4f0 fs/namei.c:3740 do_sys_openat2+0x124/0x4e0 fs/open.c:1310 do_sys_open fs/open.c:1326 [inline] __do_sys_openat fs/open.c:1342 [inline] __se_sys_openat fs/open.c:1337 [inline] __x64_sys_openat+0x243/0x290 fs/open.c:1337 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7f5d3cc3d654 Code: 84 00 00 00 00 00 44 89 54 24 0c e8 96 f9 ff ff 44 8b 54 24 0c 44 89 e2 48 89 ee 41 89 c0 bf 9c ff ff ff b8 01 01 00 00 0f 05 <48> 3d 00 f0 ff ff 77 34 44 89 c7 89 44 24 0c e8 c8 f9 ff ff 8b 44 RSP: 002b:00007f5d3d920f10 EFLAGS: 00000293 ORIG_RAX: 0000000000000101 RAX: ffffffffffffffda RBX: 0000000020000200 RCX: 00007f5d3cc3d654 RDX: 0000000000010000 RSI: 0000000020000100 RDI: 00000000ffffff9c RBP: 0000000020000100 R08: 0000000000000000 R09: 0000000020000000 R10: 0000000000000000 R11: 0000000000000293 R12: 0000000000010000 R13: 0000000020000100 R14: 00007f5d3d920fe0 R15: 0000000020005240 Allocated by task 12133: kasan_save_stack mm/kasan/common.c:45 [inline] kasan_set_track+0x3d/0x60 mm/kasan/common.c:52 ____kasan_kmalloc mm/kasan/common.c:371 [inline] __kasan_kmalloc+0x97/0xb0 mm/kasan/common.c:380 kasan_kmalloc include/linux/kasan.h:211 [inline] __do_kmalloc_node mm/slab_common.c:955 [inline] __kmalloc+0xaf/0x1a0 mm/slab_common.c:968 kmalloc_array include/linux/slab.h:628 [inline] kcalloc include/linux/slab.h:659 [inline] __list_lru_init+0xa0/0x5f0 mm/list_lru.c:571 alloc_super+0x7a7/0x920 fs/super.c:272 sget+0x20e/0x560 fs/super.c:642 mount_bdev+0xe8/0x3a0 fs/super.c:1371 legacy_get_tree+0xea/0x180 fs/fs_context.c:610 vfs_get_tree+0x88/0x270 fs/super.c:1530 do_new_mount+0x289/0xad0 fs/namespace.c:3040 do_mount fs/namespace.c:3383 [inline] __do_sys_mount fs/namespace.c:3591 [inline] __se_sys_mount+0x2d3/0x3c0 fs/namespace.c:3568 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd Freed by task 12133: kasan_save_stack mm/kasan/common.c:45 [inline] kasan_set_track+0x3d/0x60 mm/kasan/common.c:52 kasan_save_free_info+0x27/0x40 mm/kasan/generic.c:511 ____kasan_slab_free+0xd6/0x120 mm/kasan/common.c:236 kasan_slab_free include/linux/kasan.h:177 [inline] slab_free_hook mm/slub.c:1724 [inline] slab_free_freelist_hook+0x12e/0x1a0 mm/slub.c:1750 slab_free mm/slub.c:3661 [inline] __kmem_cache_free+0x71/0x110 mm/slub.c:3674 list_lru_destroy+0x752/0x830 mm/list_lru.c:598 deactivate_locked_super+0xbf/0xf0 fs/super.c:339 mount_bdev+0x288/0x3a0 fs/super.c:1402 legacy_get_tree+0xea/0x180 fs/fs_context.c:610 vfs_get_tree+0x88/0x270 fs/super.c:1530 do_new_mount+0x289/0xad0 fs/namespace.c:3040 do_mount fs/namespace.c:3383 [inline] __do_sys_mount fs/namespace.c:3591 [inline] __se_sys_mount+0x2d3/0x3c0 fs/namespace.c:3568 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd Last potentially related work creation: kasan_save_stack+0x2b/0x50 mm/kasan/common.c:45 __kasan_record_aux_stack+0xb0/0xc0 mm/kasan/generic.c:481 kvfree_call_rcu+0x112/0x880 kernel/rcu/tree.c:3343 drop_sysctl_table+0x307/0x480 fs/proc/proc_sysctl.c:1709 drop_sysctl_table+0x319/0x480 fs/proc/proc_sysctl.c:1712 unregister_sysctl_table+0x87/0x140 fs/proc/proc_sysctl.c:1747 __devinet_sysctl_unregister net/ipv4/devinet.c:2609 [inline] devinet_sysctl_unregister net/ipv4/devinet.c:2637 [inline] inetdev_event+0xdc6/0x14a0 net/ipv4/devinet.c:1610 notifier_call_chain kernel/notifier.c:87 [inline] raw_notifier_call_chain+0xe7/0x170 kernel/notifier.c:455 call_netdevice_notifiers_info net/core/dev.c:1945 [inline] call_netdevice_notifiers_extack net/core/dev.c:1983 [inline] call_netdevice_notifiers net/core/dev.c:1997 [inline] dev_change_name+0x695/0x990 net/core/dev.c:1226 do_setlink+0xa73/0x3d40 net/core/rtnetlink.c:2761 __rtnl_newlink net/core/rtnetlink.c:3547 [inline] rtnl_newlink+0x1748/0x1fa0 net/core/rtnetlink.c:3594 rtnetlink_rcv_msg+0x772/0xe60 net/core/rtnetlink.c:6091 netlink_rcv_skb+0x1f0/0x460 net/netlink/af_netlink.c:2540 netlink_unicast_kernel net/netlink/af_netlink.c:1319 [inline] netlink_unicast+0x7e7/0x9c0 net/netlink/af_netlink.c:1345 netlink_sendmsg+0x9b3/0xcd0 net/netlink/af_netlink.c:1921 sock_sendmsg_nosec net/socket.c:714 [inline] sock_sendmsg net/socket.c:734 [inline] __sys_sendto+0x46e/0x5f0 net/socket.c:2117 __do_sys_sendto net/socket.c:2129 [inline] __se_sys_sendto net/socket.c:2125 [inline] __x64_sys_sendto+0xda/0xf0 net/socket.c:2125 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd The buggy address belongs to the object at ffff88807ca06600 which belongs to the cache kmalloc-256 of size 256 The buggy address is located 152 bytes to the right of 256-byte region [ffff88807ca06600, ffff88807ca06700) The buggy address belongs to the physical page: page:ffffea0001f28180 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x7ca06 head:ffffea0001f28180 order:1 compound_mapcount:0 compound_pincount:0 flags: 0xfff00000010200(slab|head|node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000010200 ffffea0001eeac80 dead000000000004 ffff888012041b40 raw: 0000000000000000 0000000080100010 00000001ffffffff 0000000000000000 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 3639, tgid 3639 (syz-executor.3), ts 216056906891, free_ts 215683335975 prep_new_page mm/page_alloc.c:2538 [inline] get_page_from_freelist+0x742/0x7c0 mm/page_alloc.c:4287 __alloc_pages+0x259/0x560 mm/page_alloc.c:5554 alloc_slab_page+0x70/0xf0 mm/slub.c:1794 allocate_slab+0x5e/0x4b0 mm/slub.c:1939 new_slab mm/slub.c:1992 [inline] ___slab_alloc+0x782/0xe20 mm/slub.c:3180 __slab_alloc mm/slub.c:3279 [inline] slab_alloc_node mm/slub.c:3364 [inline] __kmem_cache_alloc_node+0x252/0x310 mm/slub.c:3437 __do_kmalloc_node mm/slab_common.c:954 [inline] __kmalloc+0x9e/0x1a0 mm/slab_common.c:968 kmalloc include/linux/slab.h:581 [inline] kzalloc include/linux/slab.h:712 [inline] new_dir fs/proc/proc_sysctl.c:971 [inline] get_subdir fs/proc/proc_sysctl.c:1015 [inline] __register_sysctl_table+0xb63/0x11e0 fs/proc/proc_sysctl.c:1366 __addrconf_sysctl_register+0x25e/0x3b0 net/ipv6/addrconf.c:7083 addrconf_sysctl_register+0x128/0x180 net/ipv6/addrconf.c:7130 ipv6_add_dev+0xb9d/0x1150 net/ipv6/addrconf.c:450 addrconf_notify+0x75b/0xfe0 net/ipv6/addrconf.c:3528 notifier_call_chain kernel/notifier.c:87 [inline] raw_notifier_call_chain+0xe7/0x170 kernel/notifier.c:455 call_netdevice_notifiers_info net/core/dev.c:1945 [inline] call_netdevice_notifiers_extack net/core/dev.c:1983 [inline] call_netdevice_notifiers+0x14e/0x1d0 net/core/dev.c:1997 register_netdevice+0x1316/0x1790 net/core/dev.c:10090 nsim_init_netdevsim drivers/net/netdevsim/netdev.c:317 [inline] nsim_create+0x349/0x3f0 drivers/net/netdevsim/netdev.c:365 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1458 [inline] free_pcp_prepare+0x80c/0x8f0 mm/page_alloc.c:1508 free_unref_page_prepare mm/page_alloc.c:3386 [inline] free_unref_page+0x7d/0x5f0 mm/page_alloc.c:3482 qlist_free_all+0x2b/0x70 mm/kasan/quarantine.c:187 kasan_quarantine_reduce+0x169/0x180 mm/kasan/quarantine.c:294 __kasan_slab_alloc+0x1f/0x70 mm/kasan/common.c:302 kasan_slab_alloc include/linux/kasan.h:201 [inline] slab_post_alloc_hook mm/slab.h:737 [inline] slab_alloc_node mm/slub.c:3398 [inline] __kmem_cache_alloc_node+0x1d7/0x310 mm/slub.c:3437 kmalloc_trace+0x26/0x60 mm/slab_common.c:1046 kmalloc include/linux/slab.h:576 [inline] netdev_name_node_alloc net/core/dev.c:259 [inline] netdev_name_node_head_alloc net/core/dev.c:273 [inline] register_netdevice+0x4ea/0x1790 net/core/dev.c:9981 veth_newlink+0x888/0xd10 drivers/net/veth.c:1795 rtnl_newlink_create net/core/rtnetlink.c:3364 [inline] __rtnl_newlink net/core/rtnetlink.c:3581 [inline] rtnl_newlink+0x147d/0x1fa0 net/core/rtnetlink.c:3594 rtnetlink_rcv_msg+0x772/0xe60 net/core/rtnetlink.c:6091 netlink_rcv_skb+0x1f0/0x460 net/netlink/af_netlink.c:2540 netlink_unicast_kernel net/netlink/af_netlink.c:1319 [inline] netlink_unicast+0x7e7/0x9c0 net/netlink/af_netlink.c:1345 netlink_sendmsg+0x9b3/0xcd0 net/netlink/af_netlink.c:1921 sock_sendmsg_nosec net/socket.c:714 [inline] sock_sendmsg net/socket.c:734 [inline] __sys_sendto+0x46e/0x5f0 net/socket.c:2117 __do_sys_sendto net/socket.c:2129 [inline] __se_sys_sendto net/socket.c:2125 [inline] __x64_sys_sendto+0xda/0xf0 net/socket.c:2125 Memory state around the buggy address: ffff88807ca06680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff88807ca06700: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff88807ca06780: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff88807ca06800: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff88807ca06880: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================