kernel msg: ebtables bug: please report to author: counter_offset != totalcnt x_tables: ip6_tables: rpfilter match: used from hooks OUTPUT, but only valid from PREROUTING ===================================== WARNING: bad unlock balance detected! 4.16.0-rc2+ #323 Not tainted ------------------------------------- syz-executor2/7437 is trying to release lock (rcu_read_lock_bh) at: [] rcu_read_unlock_bh include/linux/rcupdate.h:722 [inline] [] hashlimit_mt_common.isra.10+0x1beb/0x2610 net/netfilter/xt_hashlimit.c:777 but there are no more locks to release! other info that might help us debug this: 3 locks held by syz-executor2/7437: #0: (sk_lock-AF_INET6){+.+.}, at: [<0000000065722bf7>] lock_sock include/net/sock.h:1463 [inline] #0: (sk_lock-AF_INET6){+.+.}, at: [<0000000065722bf7>] sctp_sendmsg+0xc1e/0x35e0 net/sctp/socket.c:1723 #1: (rcu_read_lock){....}, at: [<0000000055d0d02f>] sctp_v6_xmit+0x2e5/0x630 net/sctp/ipv6.c:222 #2: (rcu_read_lock){....}, at: [<0000000015d84eff>] ip6_autoflowlabel net/ipv6/ip6_output.c:291 [inline] #2: (rcu_read_lock){....}, at: [<0000000015d84eff>] ip6_xmit+0xe9d/0x2260 net/ipv6/ip6_output.c:249 stack backtrace: CPU: 0 PID: 7437 Comm: syz-executor2 Not tainted 4.16.0-rc2+ #323 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+0x194/0x257 lib/dump_stack.c:53 print_unlock_imbalance_bug+0x12f/0x140 kernel/locking/lockdep.c:3484 __lock_release kernel/locking/lockdep.c:3691 [inline] lock_release+0x6fe/0xa40 kernel/locking/lockdep.c:3939 rcu_lock_release include/linux/rcupdate.h:249 [inline] rcu_read_unlock_bh include/linux/rcupdate.h:724 [inline] hashlimit_mt_common.isra.10+0x1c08/0x2610 net/netfilter/xt_hashlimit.c:777 hashlimit_mt+0x78/0x90 net/netfilter/xt_hashlimit.c:846 ip6t_do_table+0x98d/0x1a30 net/ipv6/netfilter/ip6_tables.c:319 ip6table_filter_hook+0x65/0x80 net/ipv6/netfilter/ip6table_filter.c:41 nf_hook_entry_hookfn include/linux/netfilter.h:120 [inline] nf_hook_slow+0xba/0x1a0 net/netfilter/core.c:483 nf_hook include/linux/netfilter.h:243 [inline] NF_HOOK include/linux/netfilter.h:286 [inline] ip6_xmit+0x10ec/0x2260 net/ipv6/ip6_output.c:277 sctp_v6_xmit+0x438/0x630 net/sctp/ipv6.c:225 sctp_packet_transmit+0x225e/0x3750 net/sctp/output.c:638 sctp_outq_flush+0xabb/0x4060 net/sctp/outqueue.c:911 sctp_outq_uncork+0x5a/0x70 net/sctp/outqueue.c:776 sctp_cmd_interpreter net/sctp/sm_sideeffect.c:1807 [inline] sctp_side_effects net/sctp/sm_sideeffect.c:1210 [inline] sctp_do_sm+0x4e0/0x6ed0 net/sctp/sm_sideeffect.c:1181 sctp_primitive_ASSOCIATE+0x9d/0xd0 net/sctp/primitive.c:88 sctp_sendmsg+0x13bd/0x35e0 net/sctp/socket.c:1985 inet_sendmsg+0x11f/0x5e0 net/ipv4/af_inet.c:764 sock_sendmsg_nosec net/socket.c:630 [inline] sock_sendmsg+0xca/0x110 net/socket.c:640 SYSC_sendto+0x361/0x5c0 net/socket.c:1747 SyS_sendto+0x40/0x50 net/socket.c:1715 do_syscall_64+0x280/0x940 arch/x86/entry/common.c:287 entry_SYSCALL_64_after_hwframe+0x42/0xb7 RIP: 0033:0x453da9 RSP: 002b:00007f8e7e84dc68 EFLAGS: 00000246 ORIG_RAX: 000000000000002c RAX: ffffffffffffffda RBX: 00007f8e7e84e6d4 RCX: 0000000000453da9 RDX: 0000000000000001 RSI: 00000000203aa000 RDI: 0000000000000013 RBP: 000000000072bea0 R08: 0000000020749fe4 R09: 000000000000001c R10: 0000000000000000 R11: 0000000000000246 R12: 00000000ffffffff R13: 00000000000004ba R14: 00000000006f7210 R15: 0000000000000000 binder: 7495:7505 ERROR: BC_REGISTER_LOOPER called without request binder: 7495:7505 BC_ACQUIRE_DONE uffffffffffffffff no match binder: 7495:7505 BC_DEAD_BINDER_DONE 0000000000000000 not found binder: 7495:7505 Release 1 refcount change on invalid ref 3 ret -22 binder: 7495:7505 BC_REQUEST_DEATH_NOTIFICATION invalid ref 1 binder: 7495:7505 got transaction to invalid handle binder: 7495:7505 transaction failed 29201/-22, size 56-56 line 2842 binder: 7495:7505 ERROR: BC_REGISTER_LOOPER called without request binder: 7495:7505 BC_ACQUIRE_DONE uffffffffffffffff no match binder: 7495:7505 BC_DEAD_BINDER_DONE 0000000000000000 not found binder: 7495:7505 Release 1 refcount change on invalid ref 3 ret -22 binder: 7495:7505 BC_REQUEST_DEATH_NOTIFICATION invalid ref 1 binder: 7495:7505 got transaction to invalid handle binder: 7495:7505 transaction failed 29201/-22, size 56-56 line 2842 binder: undelivered TRANSACTION_ERROR: 29201 binder: undelivered TRANSACTION_ERROR: 29201 kauditd_printk_skb: 1 callbacks suppressed audit: type=1400 audit(1519218261.170:62): avc: denied { accept } for pid=7523 comm="syz-executor5" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 IPVS: ftp: loaded support on port[0] = 21 IPv6: ADDRCONF(NETDEV_UP): bridge0: link is not ready netlink: 12 bytes leftover after parsing attributes in process `syz-executor7'. tc_dump_action: action bad kind audit: type=1400 audit(1519218262.739:63): avc: denied { relabelto } for pid=7751 comm="syz-executor4" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=system_u:object_r:sulogin_exec_t:s0 tclass=packet permissive=1 dccp_invalid_packet: P.Data Offset(0) too small audit: type=1400 audit(1519218262.739:64): avc: denied { relabelto } for pid=7751 comm="syz-executor4" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=system_u:object_r:inetd_exec_t:s0 tclass=packet permissive=1 dccp_invalid_packet: P.Data Offset(0) too small audit: type=1400 audit(1519218262.795:65): avc: denied { send } for pid=7751 comm="syz-executor4" saddr=::1 src=20016 daddr=::1 dest=20016 netif=lo scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=system_u:object_r:inetd_exec_t:s0 tclass=packet permissive=1 audit: type=1400 audit(1519218262.796:66): avc: denied { recv } for pid=7751 comm="syz-executor4" saddr=::1 src=20016 daddr=::1 dest=20016 netif=lo scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=system_u:object_r:inetd_exec_t:s0 tclass=packet permissive=1 kernel msg: ebtables bug: please report to author: Valid hook without chain kernel msg: ebtables bug: please report to author: Valid hook without chain audit: type=1400 audit(1519218262.951:67): avc: denied { map } for pid=7799 comm="syz-executor1" path="pipe:[20378]" dev="pipefs" ino=20378 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=fifo_file permissive=1 binder: 7818 RLIMIT_NICE not set binder: 7834 RLIMIT_NICE not set audit: type=1400 audit(1519218263.200:68): avc: denied { net_bind_service } for pid=7887 comm="syz-executor7" capability=10 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1519218263.367:69): avc: denied { setuid } for pid=7934 comm="syz-executor3" capability=7 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1519218263.746:70): avc: denied { ioctl } for pid=8005 comm="syz-executor7" path="socket:[21907]" dev="sockfs" ino=21907 ioctlcmd=0x891a scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_crypto_socket permissive=1 BUG: unable to handle kernel paging request at ffffc90019f8bb3c IP: ebt_among_mt_check+0x170/0x350 net/bridge/netfilter/ebt_among.c:187 PGD 1db12d067 P4D 1db12d067 PUD 1db12e067 PMD 0 Oops: 0000 [#1] SMP KASAN Dumping ftrace buffer: (ftrace buffer empty) Modules linked in: CPU: 1 PID: 8071 Comm: syz-executor3 Not tainted 4.16.0-rc2+ #323 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 RIP: 0010:ebt_among_mt_check+0x170/0x350 net/bridge/netfilter/ebt_among.c:187 RSP: 0018:ffff8801cf537210 EFLAGS: 00010246 RAX: 0000000000000007 RBX: ffffc90001cc10f8 RCX: ffffffff84f16d0e RDX: 0000000000000000 RSI: ffffc90002921000 RDI: ffffc90019f8bb3c RBP: ffff8801cf537240 R08: 0000000000000000 R09: 0000000000000000 R10: ffffffff8818b280 R11: ffff8801d27b6f30 R12: ffffc90019f8b738 R13: ffff8801cf537548 R14: ffffc90001cc10fe R15: 0000000001740414 FS: 00007fc69873b700(0000) GS:ffff8801db500000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: ffffc90019f8bb3c CR3: 00000001b89a0005 CR4: 00000000001606e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: xt_check_match+0x231/0x7d0 net/netfilter/x_tables.c:470 ebt_check_match net/bridge/netfilter/ebtables.c:374 [inline] ebt_check_entry+0xbc3/0x1e00 net/bridge/netfilter/ebtables.c:704 translate_table+0xcf5/0x2290 net/bridge/netfilter/ebtables.c:945 do_replace_finish+0x79a/0x2620 net/bridge/netfilter/ebtables.c:1002 do_replace+0x333/0x4b0 net/bridge/netfilter/ebtables.c:1141 do_ebt_set_ctl+0xd4/0x110 net/bridge/netfilter/ebtables.c:1518 nf_sockopt net/netfilter/nf_sockopt.c:106 [inline] nf_setsockopt+0x67/0xc0 net/netfilter/nf_sockopt.c:115 ip_setsockopt+0x97/0xa0 net/ipv4/ip_sockglue.c:1259 dccp_setsockopt+0x85/0xd0 net/dccp/proto.c:576 sock_common_setsockopt+0x95/0xd0 net/core/sock.c:2975 SYSC_setsockopt net/socket.c:1849 [inline] SyS_setsockopt+0x189/0x360 net/socket.c:1828 do_syscall_64+0x280/0x940 arch/x86/entry/common.c:287 entry_SYSCALL_64_after_hwframe+0x42/0xb7 RIP: 0033:0x453da9 RSP: 002b:00007fc69873ac68 EFLAGS: 00000246 ORIG_RAX: 0000000000000036 RAX: ffffffffffffffda RBX: 00007fc69873b6d4 RCX: 0000000000453da9 RDX: 0000000000000080 RSI: 0000000000000000 RDI: 0000000000000013 RBP: 000000000072bea0 R08: 0000000000000d98 R09: 0000000000000000 R10: 0000000020000d80 R11: 0000000000000246 R12: 00000000ffffffff R13: 00000000000004d4 R14: 00000000006f7480 R15: 0000000000000000 Code: 00 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 0f b6 14 02 48 89 f8 83 e0 07 83 c0 03 38 d0 7c 08 84 d2 0f 85 c9 01 00 00 <41> 8b 84 24 04 04 00 00 8d 04 40 45 8d bc 87 08 04 00 00 4d 63 RIP: ebt_among_mt_check+0x170/0x350 net/bridge/netfilter/ebt_among.c:187 RSP: ffff8801cf537210 CR2: ffffc90019f8bb3c ---[ end trace 9222d2bf1005aef4 ]---