audit: type=1400 audit(1589488676.059:8): avc: denied { execmem } for pid=6345 comm="syz-executor905" scontext=system_u:system_r:kernel_t:s0 tcontext=system_u:system_r:kernel_t:s0 tclass=process permissive=1 ================================================================== BUG: KASAN: slab-out-of-bounds in tipc_nametbl_lookup_dst_nodes+0x44c/0x4c0 net/tipc/name_table.c:670 Read of size 4 at addr ffff888098ba2590 by task syz-executor905/6345 CPU: 1 PID: 6345 Comm: syz-executor905 Not tainted 4.14.180-syzkaller #0 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+0x13e/0x194 lib/dump_stack.c:58 print_address_description.cold+0x7c/0x1e2 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+0xa9/0x2ae mm/kasan/report.c:393 tipc_nametbl_lookup_dst_nodes+0x44c/0x4c0 net/tipc/name_table.c:670 tipc_sendmcast+0x599/0xb60 net/tipc/socket.c:767 __tipc_sendmsg+0xbc5/0xfd0 net/tipc/socket.c:971 tipc_sendmsg+0x4c/0x70 net/tipc/socket.c:919 sock_sendmsg_nosec net/socket.c:646 [inline] sock_sendmsg+0xc5/0x100 net/socket.c:656 ___sys_sendmsg+0x70a/0x840 net/socket.c:2062 __sys_sendmsg+0xa3/0x120 net/socket.c:2096 SYSC_sendmsg net/socket.c:2107 [inline] SyS_sendmsg+0x27/0x40 net/socket.c:2103 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x42/0xb7 RIP: 0033:0x440289 RSP: 002b:00007ffeef8b5d48 EFLAGS: 00000246 ORIG_RAX: 000000000000002e RAX: ffffffffffffffda RBX: 00000000004002c8 RCX: 0000000000440289 RDX: 0000000000000000 RSI: 0000000020000940 RDI: 0000000000000004 RBP: 00000000006ca018 R08: 00000000004002c8 R09: 00000000004002c8 R10: 00000000004002c8 R11: 0000000000000246 R12: 0000000000401b10 R13: 0000000000401ba0 R14: 0000000000000000 R15: 0000000000000000 Allocated by task 6345: save_stack+0x32/0xa0 mm/kasan/kasan.c:447 set_track mm/kasan/kasan.c:459 [inline] kasan_kmalloc mm/kasan/kasan.c:551 [inline] kasan_kmalloc+0xbf/0xe0 mm/kasan/kasan.c:529 kmem_cache_alloc_trace+0x14d/0x7b0 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+0x7e/0x2d0 net/tipc/name_table.c:152 tipc_nametbl_insert_publ+0x6b1/0x1450 net/tipc/name_table.c:476 tipc_nametbl_publish+0x211/0x3f0 net/tipc/name_table.c:701 tipc_sk_publish net/tipc/socket.c:2203 [inline] tipc_bind+0x2c4/0x600 net/tipc/socket.c:629 SYSC_bind+0x1a0/0x1e0 net/socket.c:1489 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x42/0xb7 Freed by task 4589: save_stack+0x32/0xa0 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+0xcb/0x260 mm/slab.c:3815 security_cred_free+0x71/0xb0 security/security.c:1003 put_cred_rcu+0xe3/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+0x792/0x1190 kernel/rcu/tree.c:2946 __do_softirq+0x254/0x9bf kernel/softirq.c:288 The buggy address belongs to the object at ffff888098ba2580 which belongs to the cache kmalloc-32 of size 32 The buggy address is located 16 bytes inside of 32-byte region [ffff888098ba2580, ffff888098ba25a0) The buggy address belongs to the page: page:ffffea000262e880 count:1 mapcount:0 mapping:ffff888098ba2000 index:0xffff888098ba2fc1 flags: 0xfffe0000000100(slab) raw: 00fffe0000000100 ffff888098ba2000 ffff888098ba2fc1 0000000100000031 raw: ffffea00023c91a0 ffffea000262e960 ffff88812fe541c0 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff888098ba2480: fb fb fb fb fc fc fc fc fb fb fb fb fc fc fc fc ffff888098ba2500: 00 00 01 fc fc fc fc fc fb fb fb fb fc fc fc fc >ffff888098ba2580: 00 00 fc fc fc fc fc fc 00 01 fc fc fc fc fc fc ^ ffff888098ba2600: 00 00 fc fc fc fc fc fc 00 00 01 fc fc fc fc fc ffff888098ba2680: 00 00 01 fc fc fc fc fc 00 00 00 fc fc fc fc fc ==================================================================