nla_parse: 1 callbacks suppressed
netlink: 4 bytes leftover after parsing attributes in process `syz-executor.5'.
==================================================================
BUG: KASAN: slab-out-of-bounds in ipt_init_target+0x24e/0x290 net/sched/act_ipt.c:46
Read of size 1 at addr ffff88809d7cfe5f by task syz-executor.5/17604

CPU: 1 PID: 17604 Comm: syz-executor.5 Not tainted 4.14.171-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+0x142/0x197 lib/dump_stack.c:58
 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+0xa9/0x2af mm/kasan/report.c:393
 __asan_report_load1_noabort+0x14/0x20 mm/kasan/report.c:427
 ipt_init_target+0x24e/0x290 net/sched/act_ipt.c:46
 __tcf_ipt_init+0x48c/0xb50 net/sched/act_ipt.c:168
 tcf_ipt_init+0x4e/0x60 net/sched/act_ipt.c:202
 tcf_action_init_1+0x53c/0xaa0 net/sched/act_api.c:682
 tcf_action_init+0x2ab/0x480 net/sched/act_api.c:751
 tcf_action_add net/sched/act_api.c:1079 [inline]
 tc_ctl_action+0x30a/0x548 net/sched/act_api.c:1131
 rtnetlink_rcv_msg+0x3da/0xb70 net/core/rtnetlink.c:4315
 netlink_rcv_skb+0x14f/0x3c0 net/netlink/af_netlink.c:2432
 rtnetlink_rcv+0x1d/0x30 net/core/rtnetlink.c:4327
 netlink_unicast_kernel net/netlink/af_netlink.c:1286 [inline]
 netlink_unicast+0x44d/0x650 net/netlink/af_netlink.c:1312
 netlink_sendmsg+0x7c4/0xc60 net/netlink/af_netlink.c:1877
 sock_sendmsg_nosec net/socket.c:646 [inline]
 sock_sendmsg+0xce/0x110 net/socket.c:656
 ___sys_sendmsg+0x70a/0x840 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+0x1e8/0x640 arch/x86/entry/common.c:292
 entry_SYSCALL_64_after_hwframe+0x42/0xb7
RIP: 0033:0x45c449
RSP: 002b:00007fecf63aec78 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
RAX: ffffffffffffffda RBX: 00007fecf63af6d4 RCX: 000000000045c449
RDX: 0000000000000000 RSI: 0000000020000300 RDI: 0000000000000003
RBP: 000000000076bf20 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00000000ffffffff
R13: 00000000000009d1 R14: 00000000004cc4b4 R15: 000000000076bf2c

Allocated by task 17604:
 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
 __do_kmalloc mm/slab.c:3720 [inline]
 __kmalloc_track_caller+0x159/0x790 mm/slab.c:3735
 kmemdup+0x27/0x60 mm/util.c:118
 kmemdup include/linux/string.h:420 [inline]
 __tcf_ipt_init+0x463/0xb50 net/sched/act_ipt.c:164
 tcf_ipt_init+0x4e/0x60 net/sched/act_ipt.c:202
 tcf_action_init_1+0x53c/0xaa0 net/sched/act_api.c:682
 tcf_action_init+0x2ab/0x480 net/sched/act_api.c:751
 tcf_action_add net/sched/act_api.c:1079 [inline]
 tc_ctl_action+0x30a/0x548 net/sched/act_api.c:1131
 rtnetlink_rcv_msg+0x3da/0xb70 net/core/rtnetlink.c:4315
 netlink_rcv_skb+0x14f/0x3c0 net/netlink/af_netlink.c:2432
 rtnetlink_rcv+0x1d/0x30 net/core/rtnetlink.c:4327
 netlink_unicast_kernel net/netlink/af_netlink.c:1286 [inline]
 netlink_unicast+0x44d/0x650 net/netlink/af_netlink.c:1312
 netlink_sendmsg+0x7c4/0xc60 net/netlink/af_netlink.c:1877
 sock_sendmsg_nosec net/socket.c:646 [inline]
 sock_sendmsg+0xce/0x110 net/socket.c:656
 ___sys_sendmsg+0x70a/0x840 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+0x1e8/0x640 arch/x86/entry/common.c:292
 entry_SYSCALL_64_after_hwframe+0x42/0xb7

Freed by task 7283:
 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
 kvfree+0x4d/0x60 mm/util.c:416
 __vunmap+0x24e/0x320 mm/vmalloc.c:1547
 vfree+0x50/0xe0 mm/vmalloc.c:1611
 copy_entries_to_user net/ipv4/netfilter/ip_tables.c:867 [inline]
 get_entries net/ipv4/netfilter/ip_tables.c:1025 [inline]
 do_ipt_get_ctl+0x5e8/0x7e0 net/ipv4/netfilter/ip_tables.c:1702
 nf_sockopt net/netfilter/nf_sockopt.c:104 [inline]
 nf_getsockopt+0x6a/0xc0 net/netfilter/nf_sockopt.c:122
 ip_getsockopt net/ipv4/ip_sockglue.c:1566 [inline]
 ip_getsockopt+0x10d/0x150 net/ipv4/ip_sockglue.c:1551
 tcp_getsockopt net/ipv4/tcp.c:3255 [inline]
 tcp_getsockopt+0x84/0xd0 net/ipv4/tcp.c:3249
 sock_common_getsockopt+0x94/0xd0 net/core/sock.c:2927
 SYSC_getsockopt net/socket.c:1896 [inline]
 SyS_getsockopt+0x126/0x1e0 net/socket.c:1878
 do_syscall_64+0x1e8/0x640 arch/x86/entry/common.c:292
 entry_SYSCALL_64_after_hwframe+0x42/0xb7

The buggy address belongs to the object at ffff88809d7cfe40
 which belongs to the cache kmalloc-32 of size 32
The buggy address is located 31 bytes inside of
 32-byte region [ffff88809d7cfe40, ffff88809d7cfe60)
The buggy address belongs to the page:
page:ffffea000275f3c0 count:1 mapcount:0 mapping:ffff88809d7cf000 index:0xffff88809d7cffc1
flags: 0xfffe0000000100(slab)
raw: 00fffe0000000100 ffff88809d7cf000 ffff88809d7cffc1 000000010000003f
raw: ffffea00027e0560 ffffea0002453be0 ffff8880aa8001c0 0000000000000000
page dumped because: kasan: bad access detected

Memory state around the buggy address:
 ffff88809d7cfd00: fb fb fb fb fc fc fc fc 05 fc fc fc fc fc fc fc
 ffff88809d7cfd80: fb fb fb fb fc fc fc fc 00 00 00 00 fc fc fc fc
>ffff88809d7cfe00: 00 00 00 fc fc fc fc fc 00 01 fc fc fc fc fc fc
                                                    ^
 ffff88809d7cfe80: 00 00 00 fc fc fc fc fc 00 00 00 fc fc fc fc fc
 ffff88809d7cff00: 00 00 00 fc fc fc fc fc 00 00 00 fc fc fc fc fc
==================================================================