R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007f347f226038 R14: 00007f347f225fa0 R15: 00007fffe1275168 ================================================================== BUG: KASAN: slab-out-of-bounds in md5_block+0x95/0x8d0 lib/crypto/md5.c:40 Read of size 64 at addr ffff88803e1ef2e0 by task syz.1.593/8081 CPU: 3 UID: 0 PID: 8081 Comm: syz.1.593 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+0x13d/0x4b0 mm/kasan/report.c:482 kasan_report+0xdf/0x1c0 mm/kasan/report.c:595 check_region_inline mm/kasan/generic.c:186 [inline] kasan_check_range+0x10f/0x1e0 mm/kasan/generic.c:200 __asan_memcpy+0x23/0x60 mm/kasan/shadow.c:105 md5_block+0x95/0x8d0 lib/crypto/md5.c:40 md5_blocks lib/crypto/md5.c:126 [inline] md5_update+0xf7/0x210 lib/crypto/md5.c:161 md5+0xc7/0x120 lib/crypto/md5.c:202 ecryptfs_write_tag_70_packet+0x880/0x1410 fs/ecryptfs/keystore.c:741 ecryptfs_encrypt_filename fs/ecryptfs/crypto.c:1378 [inline] ecryptfs_encrypt_and_encode_filename+0x428/0xa60 fs/ecryptfs/crypto.c:1789 ecryptfs_lookup+0x1f7/0x830 fs/ecryptfs/inode.c:402 __lookup_slow+0x155/0x320 fs/namei.c:1919 lookup_slow+0x50/0x70 fs/namei.c:1936 walk_component fs/namei.c:2311 [inline] lookup_last fs/namei.c:2818 [inline] path_lookupat+0x5e8/0xc40 fs/namei.c:2842 filename_lookup+0x202/0x590 fs/namei.c:2871 user_path_at+0x3c/0x60 fs/namei.c:3670 do_mount fs/namespace.c:4322 [inline] __do_sys_mount fs/namespace.c:4543 [inline] __se_sys_mount fs/namespace.c:4520 [inline] __x64_sys_mount+0x1fb/0x310 fs/namespace.c:4520 do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline] do_syscall_64+0x123/0x790 arch/x86/entry/syscall_64.c:84 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f347ef9e559 Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 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 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f347d1f6028 EFLAGS: 00000246 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 00007f347f225fa0 RCX: 00007f347ef9e559 RDX: 0000200000000180 RSI: 0000200000000040 RDI: 0000000000000000 RBP: 00007f347f0358b0 R08: 0000200000004880 R09: 0000000000000000 R10: 0000000000020000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007f347f226038 R14: 00007f347f225fa0 R15: 00007fffe1275168 Allocated by task 8081: kasan_save_stack+0x30/0x50 mm/kasan/common.c:57 kasan_save_track+0x14/0x30 mm/kasan/common.c:78 poison_kmalloc_redzone mm/kasan/common.c:409 [inline] __kasan_kmalloc+0xaa/0xb0 mm/kasan/common.c:426 kasan_kmalloc include/linux/kasan.h:263 [inline] __do_kmalloc_node mm/slub.c:5414 [inline] __kmalloc_flags_noprof+0x370/0x8e0 mm/slub.c:5602 _kmalloc_flags_noprof mm/slab.h:55 [inline] __alloc_empty_sheaf mm/slub.c:2822 [inline] alloc_empty_sheaf mm/slub.c:2842 [inline] __pcs_replace_empty_main+0x3fa/0x650 mm/slub.c:4769 alloc_from_pcs mm/slub.c:4850 [inline] slab_alloc_node mm/slub.c:4984 [inline] kmem_cache_alloc_noprof+0x4c4/0x6a0 mm/slub.c:5010 ecryptfs_add_new_key_tfm+0xa9/0x590 fs/ecryptfs/crypto.c:1506 ecryptfs_validate_options fs/ecryptfs/main.c:386 [inline] ecryptfs_get_tree+0xd72/0x15b0 fs/ecryptfs/main.c:453 vfs_get_tree+0x92/0x320 fs/super.c:1932 fc_mount fs/namespace.c:1278 [inline] do_new_mount_fc fs/namespace.c:3885 [inline] do_new_mount fs/namespace.c:3961 [inline] path_mount+0x7d0/0x2850 fs/namespace.c:4312 do_mount fs/namespace.c:4325 [inline] __do_sys_mount fs/namespace.c:4543 [inline] __se_sys_mount fs/namespace.c:4520 [inline] __x64_sys_mount+0x293/0x310 fs/namespace.c:4520 do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline] do_syscall_64+0x123/0x790 arch/x86/entry/syscall_64.c:84 entry_SYSCALL_64_after_hwframe+0x77/0x7f The buggy address belongs to the object at ffff88803e1ef200 which belongs to the cache kmalloc-256 of size 256 The buggy address is located 224 bytes inside of allocated 256-byte region [ffff88803e1ef200, ffff88803e1ef300) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x3e1ee head: order:1 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 flags: 0xfff00000000040(head|node=0|zone=1|lastcpupid=0x7ff) page_type: f5(slab) raw: 00fff00000000040 ffff88801d042b40 dead000000000100 dead000000000122 raw: 0000000000000000 0000000000100010 00000000f5000000 0000000000000000 head: 00fff00000000040 ffff88801d042b40 dead000000000100 dead000000000122 head: 0000000000000000 0000000000100010 00000000f5000000 0000000000000000 head: 00fff00000000001 ffffffffffffff81 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 5729, tgid 5729 (syz-executor), ts 47238845389 set_page_owner include/linux/page_owner.h:33 [inline] post_alloc_hook+0xfd/0x120 mm/page_alloc.c:1871 prep_new_page mm/page_alloc.c:1879 [inline] get_page_from_freelist+0x110d/0x35d0 mm/page_alloc.c:3943 __alloc_frozen_pages_noprof+0x2eb/0x3300 mm/page_alloc.c:5436 alloc_slab_page mm/slub.c:3347 [inline] allocate_slab mm/slub.c:3462 [inline] new_slab+0xa9/0x6e0 mm/slub.c:3513 refill_objects+0xe3/0x410 mm/slub.c:7418 refill_sheaf mm/slub.c:2885 [inline] __pcs_replace_empty_main+0x35e/0x650 mm/slub.c:4774 alloc_from_pcs mm/slub.c:4850 [inline] slab_alloc_node mm/slub.c:4984 [inline] __do_kmalloc_node mm/slub.c:5413 [inline] __kmalloc_noprof+0x67c/0x840 mm/slub.c:5439 _kmalloc_noprof include/linux/slab.h:995 [inline] _kzalloc_noprof include/linux/slab.h:1312 [inline] new_dir fs/proc/proc_sysctl.c:965 [inline] get_subdir fs/proc/proc_sysctl.c:1009 [inline] sysctl_mkdir_p fs/proc/proc_sysctl.c:1319 [inline] __register_sysctl_table+0xbe4/0x1650 fs/proc/proc_sysctl.c:1394 register_net_sysctl_sz+0x325/0x420 net/sysctl_net.c:172 __devinet_sysctl_register+0x1b9/0x360 net/ipv4/devinet.c:2745 devinet_sysctl_register net/ipv4/devinet.c:2785 [inline] devinet_sysctl_register+0x17b/0x210 net/ipv4/devinet.c:2775 inetdev_init+0x2b8/0x570 net/ipv4/devinet.c:291 inetdev_event+0x827/0x17f0 net/ipv4/devinet.c:1590 notifier_call_chain+0x99/0x3f0 kernel/notifier.c:85 call_netdevice_notifiers_info+0xbe/0x110 net/core/dev.c:2275 call_netdevice_notifiers_extack net/core/dev.c:2313 [inline] call_netdevice_notifiers net/core/dev.c:2327 [inline] register_netdevice+0x1998/0x25a0 net/core/dev.c:11587 page last free pid 5729 tgid 5729 ts 47207326635 stack trace: reset_page_owner include/linux/page_owner.h:26 [inline] __free_pages_prepare mm/page_alloc.c:1418 [inline] __free_frozen_pages+0x79f/0x10f0 mm/page_alloc.c:2962 qlink_free mm/kasan/quarantine.c:163 [inline] qlist_free_all+0x47/0xf0 mm/kasan/quarantine.c:179 kasan_quarantine_reduce+0x1a0/0x1f0 mm/kasan/quarantine.c:286 __kasan_slab_alloc+0x69/0x90 mm/kasan/common.c:361 kasan_slab_alloc include/linux/kasan.h:253 [inline] slab_post_alloc_hook mm/slub.c:4683 [inline] slab_alloc_node mm/slub.c:4996 [inline] __do_kmalloc_node mm/slub.c:5413 [inline] __kmalloc_noprof+0x2cc/0x840 mm/slub.c:5439 _kmalloc_noprof include/linux/slab.h:995 [inline] _kzalloc_noprof include/linux/slab.h:1312 [inline] ethnl_default_notify+0x178/0x9f0 net/ethtool/netlink.c:1015 ethnl_notify+0x17c/0x360 net/ethtool/netlink.c:1112 ethtool_notify net/ethtool/netlink.c:1120 [inline] ethnl_notify_features net/ethtool/netlink.c:1128 [inline] ethnl_netdev_event+0x152/0x190 net/ethtool/netlink.c:1143 notifier_call_chain+0x99/0x3f0 kernel/notifier.c:85 call_netdevice_notifiers_info+0xbe/0x110 net/core/dev.c:2275 call_netdevice_notifiers_extack net/core/dev.c:2313 [inline] call_netdevice_notifiers net/core/dev.c:2327 [inline] netdev_features_change net/core/dev.c:1612 [inline] netdev_change_features net/core/dev.c:11228 [inline] netdev_compute_master_upper_features+0x7d4/0xa50 net/core/dev.c:13133 team_port_add drivers/net/team/team_core.c:1378 [inline] team_add_slave+0x121b/0x1ea0 drivers/net/team/team_core.c:2113 do_set_master+0x40f/0x730 net/core/rtnetlink.c:3076 do_setlink.isra.0+0xb2b/0x3e60 net/core/rtnetlink.c:3278 rtnl_changelink net/core/rtnetlink.c:3910 [inline] __rtnl_newlink net/core/rtnetlink.c:4081 [inline] rtnl_newlink+0x13c1/0x2620 net/core/rtnetlink.c:4220 rtnetlink_rcv_msg+0x95e/0xe90 net/core/rtnetlink.c:7137 Memory state around the buggy address: ffff88803e1ef200: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88803e1ef280: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff88803e1ef300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff88803e1ef380: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88803e1ef400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================