kernel msg: ebtables bug: please report to author: entries_size too small ================================================================== BUG: KASAN: slab-out-of-bounds in atomic_read include/asm-generic/atomic-instrumented.h:21 [inline] BUG: KASAN: slab-out-of-bounds in atomic_fetch_add_unless include/linux/atomic.h:575 [inline] BUG: KASAN: slab-out-of-bounds in atomic_add_unless include/linux/atomic.h:597 [inline] BUG: KASAN: slab-out-of-bounds in dst_hold_safe include/net/dst.h:308 [inline] BUG: KASAN: slab-out-of-bounds in ip6_hold_safe+0xa7/0x3a0 net/ipv6/route.c:1023 Read of size 4 at addr ffff88808f824ef8 by task syz-executor.4/19351 CPU: 0 PID: 19351 Comm: syz-executor.4 Not tainted 5.0.0-rc6+ #68 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x172/0x1f0 lib/dump_stack.c:113 print_address_description.cold+0x7c/0x20d mm/kasan/report.c:187 kasan_report.cold+0x1b/0x40 mm/kasan/report.c:317 check_memory_region_inline mm/kasan/generic.c:185 [inline] check_memory_region+0x123/0x190 mm/kasan/generic.c:191 kasan_check_read+0x11/0x20 mm/kasan/common.c:100 atomic_read include/asm-generic/atomic-instrumented.h:21 [inline] atomic_fetch_add_unless include/linux/atomic.h:575 [inline] atomic_add_unless include/linux/atomic.h:597 [inline] dst_hold_safe include/net/dst.h:308 [inline] ip6_hold_safe+0xa7/0x3a0 net/ipv6/route.c:1023 rt6_get_pcpu_route net/ipv6/route.c:1243 [inline] ip6_pol_route+0x33d/0xf00 net/ipv6/route.c:1892 ip6_pol_route_output+0x54/0x70 net/ipv6/route.c:2068 __fib6_rule_action net/ipv6/fib6_rules.c:233 [inline] fib6_rule_action+0x3ac/0xab0 net/ipv6/fib6_rules.c:264 fib_rules_lookup+0x351/0xa90 net/core/fib_rules.c:304 fib6_rule_lookup+0x33c/0x560 net/ipv6/fib6_rules.c:110 ip6_route_output_flags+0x2c4/0x350 net/ipv6/route.c:2097 ip6_route_output include/net/ip6_route.h:88 [inline] ip6_dst_lookup_tail+0xd10/0x1b30 net/ipv6/ip6_output.c:958 ip6_dst_lookup_flow+0xa8/0x220 net/ipv6/ip6_output.c:1086 ip6_datagram_dst_update+0x5cf/0xc20 net/ipv6/datagram.c:91 __ip6_datagram_connect+0x5e9/0x1390 net/ipv6/datagram.c:250 ip6_datagram_connect+0x30/0x50 net/ipv6/datagram.c:273 inet_dgram_connect+0x150/0x2e0 net/ipv4/af_inet.c:571 __sys_connect+0x266/0x330 net/socket.c:1684 __do_sys_connect net/socket.c:1695 [inline] __se_sys_connect net/socket.c:1692 [inline] __x64_sys_connect+0x73/0xb0 net/socket.c:1692 do_syscall_64+0x103/0x610 arch/x86/entry/common.c:290 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x457e29 Code: ad b8 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 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 0f 83 7b b8 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007f0ff16efc78 EFLAGS: 00000246 ORIG_RAX: 000000000000002a RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 0000000000457e29 RDX: 000000000000001c RSI: 0000000020000080 RDI: 0000000000000004 RBP: 000000000073bfa0 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00007f0ff16f06d4 R13: 00000000004be25c R14: 00000000004ce948 R15: 00000000ffffffff Allocated by task 29163: save_stack+0x45/0xd0 mm/kasan/common.c:73 set_track mm/kasan/common.c:85 [inline] __kasan_kmalloc mm/kasan/common.c:496 [inline] __kasan_kmalloc.constprop.0+0xcf/0xe0 mm/kasan/common.c:469 kasan_kmalloc mm/kasan/common.c:504 [inline] kasan_slab_alloc+0xf/0x20 mm/kasan/common.c:411 kmem_cache_alloc+0x12d/0x710 mm/slab.c:3543 dst_alloc+0x10e/0x200 net/core/dst.c:109 ip6_dst_alloc+0x34/0xa0 net/ipv6/route.c:355 ip6_rt_pcpu_alloc net/ipv6/route.c:1223 [inline] rt6_make_pcpu_route net/ipv6/route.c:1253 [inline] ip6_pol_route+0x672/0xf00 net/ipv6/route.c:1895 ip6_pol_route_output+0x54/0x70 net/ipv6/route.c:2068 fib6_rule_lookup+0x128/0x560 net/ipv6/fib6_rules.c:118 ip6_route_output_flags+0x2c4/0x350 net/ipv6/route.c:2097 ip6_route_output include/net/ip6_route.h:88 [inline] ip6_dst_lookup_tail+0xd10/0x1b30 net/ipv6/ip6_output.c:958 ip6_dst_lookup_flow+0xa8/0x220 net/ipv6/ip6_output.c:1086 ip6_datagram_dst_update+0x5cf/0xc20 net/ipv6/datagram.c:91 __ip6_datagram_connect+0x5e9/0x1390 net/ipv6/datagram.c:250 ip6_datagram_connect+0x30/0x50 net/ipv6/datagram.c:273 inet_dgram_connect+0x150/0x2e0 net/ipv4/af_inet.c:571 __sys_connect+0x266/0x330 net/socket.c:1684 __do_sys_connect net/socket.c:1695 [inline] __se_sys_connect net/socket.c:1692 [inline] __x64_sys_connect+0x73/0xb0 net/socket.c:1692 do_syscall_64+0x103/0x610 arch/x86/entry/common.c:290 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 7577: save_stack+0x45/0xd0 mm/kasan/common.c:73 set_track mm/kasan/common.c:85 [inline] __kasan_slab_free+0x102/0x150 mm/kasan/common.c:458 kasan_slab_free+0xe/0x10 mm/kasan/common.c:466 __cache_free mm/slab.c:3487 [inline] kmem_cache_free+0x86/0x260 mm/slab.c:3749 dst_destroy+0x2a0/0x3c0 net/core/dst.c:145 dst_destroy_rcu+0x16/0x19 net/core/dst.c:158 __rcu_reclaim kernel/rcu/rcu.h:240 [inline] rcu_do_batch kernel/rcu/tree.c:2452 [inline] invoke_rcu_callbacks kernel/rcu/tree.c:2773 [inline] rcu_process_callbacks+0x928/0x1390 kernel/rcu/tree.c:2754 __do_softirq+0x266/0x95a kernel/softirq.c:292 The buggy address belongs to the object at ffff88808f824dc0 which belongs to the cache ip6_dst_cache of size 224 The buggy address is located 88 bytes to the right of 224-byte region [ffff88808f824dc0, ffff88808f824ea0) The buggy address belongs to the page: page:ffffea00023e0900 count:1 mapcount:0 mapping:ffff88809ae20c80 index:0x0 flags: 0x1fffc0000000200(slab) raw: 01fffc0000000200 ffffea0001ac0a88 ffffea00021c9488 ffff88809ae20c80 raw: 0000000000000000 ffff88808f824000 000000010000000c 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff88808f824d80: fc fc fc fc fc fc fc fc 00 00 00 00 00 00 00 00 ffff88808f824e00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff88808f824e80: 00 00 00 00 fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff88808f824f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88808f824f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================