BUG: KASAN: slab-out-of-bounds in tipc_nametbl_lookup_dst_nodes+0x448/0x4b0 net/tipc/name_table.c:670 Read of size 4 at addr ffff8801ce886c10 by task syz-executor0/2995 CPU: 0 PID: 2995 Comm: syz-executor0 Not tainted 4.14.0-rc3+ #23 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:16 [inline] dump_stack+0x194/0x257 lib/dump_stack.c:52 print_address_description+0x73/0x250 mm/kasan/report.c:252 kasan_report_error mm/kasan/report.c:351 [inline] kasan_report+0x25b/0x340 mm/kasan/report.c:409 __asan_report_load4_noabort+0x14/0x20 mm/kasan/report.c:429 tipc_nametbl_lookup_dst_nodes+0x448/0x4b0 net/tipc/name_table.c:670 tipc_sendmcast+0x70b/0xe20 net/tipc/socket.c:767 __tipc_sendmsg+0xf49/0x1590 net/tipc/socket.c:971 tipc_sendmsg+0x50/0x70 net/tipc/socket.c:919 sock_sendmsg_nosec net/socket.c:633 [inline] sock_sendmsg+0xca/0x110 net/socket.c:643 ___sys_sendmsg+0x75b/0x8a0 net/socket.c:2049 __sys_sendmsg+0xe5/0x210 net/socket.c:2083 C_SYSC_sendmsg net/compat.c:739 [inline] compat_SyS_sendmsg+0x2a/0x40 net/compat.c:737 do_syscall_32_irqs_on arch/x86/entry/common.c:329 [inline] do_fast_syscall_32+0x3f2/0xf05 arch/x86/entry/common.c:391 entry_SYSENTER_compat+0x51/0x60 arch/x86/entry/entry_64_compat.S:124 RIP: 0023:0xf7f6bc79 RSP: 002b:00000000ff91159c EFLAGS: 00000292 ORIG_RAX: 0000000000000172 RAX: ffffffffffffffda RBX: 0000000000000004 RCX: 0000000020316000 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000 RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000 R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 Allocated by task 2995: save_stack_trace+0x16/0x20 arch/x86/kernel/stacktrace.c:59 save_stack+0x43/0xd0 mm/kasan/kasan.c:447 set_track mm/kasan/kasan.c:459 [inline] kasan_kmalloc+0xad/0xe0 mm/kasan/kasan.c:551 kmem_cache_alloc_trace+0x136/0x750 mm/slab.c:3627 kmalloc include/linux/slab.h:493 [inline] kmalloc_array include/linux/slab.h:611 [inline] kcalloc include/linux/slab.h:623 [inline] tipc_subseq_alloc net/tipc/name_table.c:141 [inline] tipc_nameseq_create+0xe8/0x540 net/tipc/name_table.c:152 tipc_nametbl_insert_publ+0xf77/0x17c0 net/tipc/name_table.c:476 tipc_nametbl_publish+0x2aa/0x4f0 net/tipc/name_table.c:701 tipc_sk_publish net/tipc/socket.c:2201 [inline] tipc_bind+0x33a/0x700 net/tipc/socket.c:629 SYSC_bind+0x1b4/0x3f0 net/socket.c:1476 SyS_bind+0x24/0x30 net/socket.c:1462 do_syscall_32_irqs_on arch/x86/entry/common.c:329 [inline] do_fast_syscall_32+0x3f2/0xf05 arch/x86/entry/common.c:391 entry_SYSENTER_compat+0x51/0x60 arch/x86/entry/entry_64_compat.S:124 Freed by task 1552: save_stack_trace+0x16/0x20 arch/x86/kernel/stacktrace.c:59 save_stack+0x43/0xd0 mm/kasan/kasan.c:447 set_track mm/kasan/kasan.c:459 [inline] kasan_slab_free+0x71/0xc0 mm/kasan/kasan.c:524 __cache_free mm/slab.c:3503 [inline] kfree+0xca/0x250 mm/slab.c:3820 single_release+0x88/0xb0 fs/seq_file.c:602 close_pdeo+0x130/0x420 fs/proc/inode.c:164 proc_reg_release+0x12b/0x170 fs/proc/inode.c:375 __fput+0x333/0x7f0 fs/file_table.c:210 ____fput+0x15/0x20 fs/file_table.c:244 task_work_run+0x199/0x270 kernel/task_work.c:112 tracehook_notify_resume include/linux/tracehook.h:191 [inline] exit_to_usermode_loop+0x296/0x310 arch/x86/entry/common.c:162 prepare_exit_to_usermode arch/x86/entry/common.c:197 [inline] syscall_return_slowpath+0x42f/0x510 arch/x86/entry/common.c:266 entry_SYSCALL_64_fastpath+0xbc/0xbe The buggy address belongs to the object at ffff8801ce886c00 which belongs to the cache kmalloc-32 of size 32 The buggy address is located 16 bytes inside of 32-byte region [ffff8801ce886c00, ffff8801ce886c20) The buggy address belongs to the page: page:ffffea00073a2180 count:1 mapcount:0 mapping:ffff8801ce886000 index:0xffff8801ce886fc1 flags: 0x200000000000100(slab) raw: 0200000000000100 ffff8801ce886000 ffff8801ce886fc1 000000010000003f raw: ffffea00073d51e0 ffffea00073c2960 ffff8801dac001c0 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8801ce886b00: fb fb fb fb fc fc fc fc fb fb fb fb fc fc fc fc ffff8801ce886b80: fb fb fb fb fc fc fc fc 00 00 00 00 fc fc fc fc >ffff8801ce886c00: 00 00 fc fc fc fc fc fc fb fb fb fb fc fc fc fc ^ ffff8801ce886c80: 00 00 fc fc fc fc fc fc fb fb fb fb fc fc fc fc ffff8801ce886d00: fb fb fb fb fc fc fc fc fb fb fb fb fc fc fc fc ==================================================================