lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20210609095730.185982-1-heying24@huawei.com>
Date:   Wed, 9 Jun 2021 05:57:30 -0400
From:   He Ying <heying24@...wei.com>
To:     <pablo@...filter.org>, <kadlec@...filter.org>, <fw@...len.de>,
        <davem@...emloft.net>, <kuba@...nel.org>
CC:     <netfilter-devel@...r.kernel.org>, <coreteam@...filter.org>,
        <netdev@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
        <heying24@...wei.com>
Subject: [PATCH -next] netfilter: Make NETFILTER_NETLINK_HOOK depends on NF_TABLES

Compiling errors happen when CONFIG_NETFILTER_NETLINK_HOOK = y
while CONFIG_NF_TABLES is not set:

net/netfilter/nfnetlink_hook.c: In function ‘nfnl_hook_put_nft_chain_info’:
net/netfilter/nfnetlink_hook.c:76:7: error: implicit declaration of function
‘nft_is_active’ [-Werror=implicit-function-declaration]
   76 |  if (!nft_is_active(net, chain))
      |       ^~~~~~~~~~~~~

Notice that nft_is_active macro is only defined when CONFIG_NF_TABLES
is enabled, so add dependency on NF_TABLES in NETFILTER_NETLINK_HOOK
configurations.

Fixes: e2cf17d3774c ("netfilter: add new hook nfnl subsystem")
Reported-by: Hulk Robot <hulkci@...wei.com>
Signed-off-by: He Ying <heying24@...wei.com>
---
 net/netfilter/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/net/netfilter/Kconfig b/net/netfilter/Kconfig
index c81321372198..54395266339d 100644
--- a/net/netfilter/Kconfig
+++ b/net/netfilter/Kconfig
@@ -22,6 +22,7 @@ config NETFILTER_FAMILY_ARP
 config NETFILTER_NETLINK_HOOK
 	tristate "Netfilter base hook dump support"
 	depends on NETFILTER_ADVANCED
+	depends on NF_TABLES
 	select NETFILTER_NETLINK
 	help
 	  If this option is enabled, the kernel will include support
-- 
2.17.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ