================================================================== BUG: KASAN: slab-out-of-bounds in tipc_nametbl_lookup_dst_nodes+0x46c/0x4e0 net/tipc/name_table.c:670 Read of size 4 at addr ffff8880a0d79250 by task syz-executor.3/12342 CPU: 1 PID: 12342 Comm: syz-executor.3 Not tainted 4.14.111 #1 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x138/0x19c lib/dump_stack.c:53 print_address_description.cold+0x7c/0x1dc mm/kasan/report.c:252 kasan_report_error mm/kasan/report.c:351 [inline] kasan_report mm/kasan/report.c:409 [inline] kasan_report.cold+0xaf/0x2b5 mm/kasan/report.c:393 __asan_report_load4_noabort+0x14/0x20 mm/kasan/report.c:429 tipc_nametbl_lookup_dst_nodes+0x46c/0x4e0 net/tipc/name_table.c:670 tipc_sendmcast+0x5a2/0xb70 net/tipc/socket.c:767 __tipc_sendmsg+0xc7f/0x10f0 net/tipc/socket.c:971 tipc_sendmsg+0x53/0x80 net/tipc/socket.c:919 sock_sendmsg_nosec net/socket.c:646 [inline] sock_sendmsg+0xd0/0x110 net/socket.c:656 ___sys_sendmsg+0x70c/0x850 net/socket.c:2062 __sys_sendmsg+0xb9/0x140 net/socket.c:2096 SYSC_sendmsg net/socket.c:2107 [inline] SyS_sendmsg+0x2d/0x50 net/socket.c:2103 do_syscall_64+0x1eb/0x630 arch/x86/entry/common.c:289 entry_SYSCALL_64_after_hwframe+0x42/0xb7 RIP: 0033:0x4582f9 RSP: 002b:00007fce2fb92c78 EFLAGS: 00000246 ORIG_RAX: 000000000000002e RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 00000000004582f9 RDX: 0000000000000000 RSI: 0000000020002140 RDI: 0000000000000004 RBP: 000000000073bf00 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00007fce2fb936d4 R13: 00000000004c59b1 R14: 00000000004d9cc0 R15: 00000000ffffffff Allocated by task 6997: save_stack_trace+0x16/0x20 arch/x86/kernel/stacktrace.c:59 save_stack+0x45/0xd0 mm/kasan/kasan.c:447 set_track mm/kasan/kasan.c:459 [inline] kasan_kmalloc mm/kasan/kasan.c:551 [inline] kasan_kmalloc+0xce/0xf0 mm/kasan/kasan.c:529 kmem_cache_alloc_trace+0x152/0x790 mm/slab.c:3618 kmalloc include/linux/slab.h:488 [inline] kmalloc_array include/linux/slab.h:606 [inline] kcalloc include/linux/slab.h:618 [inline] tipc_subseq_alloc net/tipc/name_table.c:141 [inline] tipc_nameseq_create+0x83/0x2e0 net/tipc/name_table.c:152 tipc_nametbl_insert_publ+0x6ae/0x1400 net/tipc/name_table.c:476 tipc_nametbl_publish+0x20f/0x3f0 net/tipc/name_table.c:701 tipc_sk_publish net/tipc/socket.c:2203 [inline] tipc_bind+0x2d3/0x610 net/tipc/socket.c:629 kernel_bind+0x67/0x80 net/socket.c:3313 tipc_create_listen_sock net/tipc/server.c:338 [inline] tipc_open_listening_sock net/tipc/server.c:396 [inline] tipc_server_start+0x329/0x8a0 net/tipc/server.c:611 tipc_topsrv_start+0x54e/0x740 net/tipc/subscr.c:382 tipc_init_net+0x2aa/0x420 net/tipc/core.c:74 ops_init+0xac/0x3d0 net/core/net_namespace.c:118 setup_net+0x223/0x520 net/core/net_namespace.c:294 copy_net_ns+0x19f/0x440 net/core/net_namespace.c:418 create_new_namespaces+0x37b/0x720 kernel/nsproxy.c:107 unshare_nsproxy_namespaces+0xab/0x1e0 kernel/nsproxy.c:206 SYSC_unshare kernel/fork.c:2379 [inline] SyS_unshare+0x2f3/0x7e0 kernel/fork.c:2329 do_syscall_64+0x1eb/0x630 arch/x86/entry/common.c:289 entry_SYSCALL_64_after_hwframe+0x42/0xb7 Freed by task 17: save_stack_trace+0x16/0x20 arch/x86/kernel/stacktrace.c:59 save_stack+0x45/0xd0 mm/kasan/kasan.c:447 set_track mm/kasan/kasan.c:459 [inline] kasan_slab_free+0x75/0xc0 mm/kasan/kasan.c:524 __cache_free mm/slab.c:3496 [inline] kfree+0xcc/0x270 mm/slab.c:3815 selinux_cred_free+0x51/0x80 security/selinux/hooks.c:3813 security_cred_free+0x7f/0xc0 security/security.c:1003 put_cred_rcu+0xe6/0x300 kernel/cred.c:117 __rcu_reclaim kernel/rcu/rcu.h:195 [inline] rcu_do_batch kernel/rcu/tree.c:2699 [inline] invoke_rcu_callbacks kernel/rcu/tree.c:2962 [inline] __rcu_process_callbacks kernel/rcu/tree.c:2929 [inline] rcu_process_callbacks+0x7c0/0x12c0 kernel/rcu/tree.c:2946 __do_softirq+0x24e/0x9ae kernel/softirq.c:288 The buggy address belongs to the object at ffff8880a0d79240 which belongs to the cache kmalloc-32 of size 32 The buggy address is located 16 bytes inside of 32-byte region [ffff8880a0d79240, ffff8880a0d79260) The buggy address belongs to the page: page:ffffea0002835e40 count:1 mapcount:0 mapping:ffff8880a0d79000 index:0xffff8880a0d79fc1 flags: 0x1fffc0000000100(slab) raw: 01fffc0000000100 ffff8880a0d79000 ffff8880a0d79fc1 000000010000003d raw: ffffea000281d1e0 ffffea000282eee0 ffff8880aa8001c0 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880a0d79100: fb fb fb fb fc fc fc fc 00 00 fc fc fc fc fc fc ffff8880a0d79180: fb fb fb fb fc fc fc fc 00 00 fc fc fc fc fc fc >ffff8880a0d79200: fb fb fb fb fc fc fc fc 00 00 fc fc fc fc fc fc ^ ffff8880a0d79280: 00 00 01 fc fc fc fc fc 00 00 01 fc fc fc fc fc ffff8880a0d79300: 00 00 01 fc fc fc fc fc 00 00 01 fc fc fc fc fc ==================================================================