netfilter: Kconfig: Change select IPv6 dependencies
... from IPV6 to NF_TABLES_IPV6 and IP6_NF_IPTABLES. In some cases module selects depend on IPV6, but this means that they select another module even if eg. NF_TABLES_IPV6 is not set in which case the selected module is useless due to the lack of IPv6 nf_tables functionality. The same applies for IP6_NF_IPTABLES and iptables. Joint work with: Arnd Bermann <arnd@arndb.de> Signed-off-by: Máté Eckl <ecklm94@gmail.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
This commit is contained in:
parent
a0ae2562c6
commit
5d400a4933
|
@ -628,7 +628,7 @@ config NFT_SOCKET
|
||||||
tristate "Netfilter nf_tables socket match support"
|
tristate "Netfilter nf_tables socket match support"
|
||||||
depends on IPV6 || IPV6=n
|
depends on IPV6 || IPV6=n
|
||||||
select NF_SOCKET_IPV4
|
select NF_SOCKET_IPV4
|
||||||
select NF_SOCKET_IPV6 if IPV6
|
select NF_SOCKET_IPV6 if NF_TABLES_IPV6
|
||||||
help
|
help
|
||||||
This option allows matching for the presence or absence of a
|
This option allows matching for the presence or absence of a
|
||||||
corresponding socket and its attributes.
|
corresponding socket and its attributes.
|
||||||
|
@ -894,7 +894,7 @@ config NETFILTER_XT_TARGET_LOG
|
||||||
tristate "LOG target support"
|
tristate "LOG target support"
|
||||||
select NF_LOG_COMMON
|
select NF_LOG_COMMON
|
||||||
select NF_LOG_IPV4
|
select NF_LOG_IPV4
|
||||||
select NF_LOG_IPV6 if IPV6
|
select NF_LOG_IPV6 if IP6_NF_IPTABLES
|
||||||
default m if NETFILTER_ADVANCED=n
|
default m if NETFILTER_ADVANCED=n
|
||||||
help
|
help
|
||||||
This option adds a `LOG' target, which allows you to create rules in
|
This option adds a `LOG' target, which allows you to create rules in
|
||||||
|
@ -986,7 +986,7 @@ config NETFILTER_XT_TARGET_TEE
|
||||||
depends on IPV6 || IPV6=n
|
depends on IPV6 || IPV6=n
|
||||||
depends on !NF_CONNTRACK || NF_CONNTRACK
|
depends on !NF_CONNTRACK || NF_CONNTRACK
|
||||||
select NF_DUP_IPV4
|
select NF_DUP_IPV4
|
||||||
select NF_DUP_IPV6 if IPV6
|
select NF_DUP_IPV6 if IP6_NF_IPTABLES
|
||||||
---help---
|
---help---
|
||||||
This option adds a "TEE" target with which a packet can be cloned and
|
This option adds a "TEE" target with which a packet can be cloned and
|
||||||
this clone be rerouted to another nexthop.
|
this clone be rerouted to another nexthop.
|
||||||
|
|
|
@ -31,7 +31,7 @@ static void nft_socket_eval(const struct nft_expr *expr,
|
||||||
case NFPROTO_IPV4:
|
case NFPROTO_IPV4:
|
||||||
sk = nf_sk_lookup_slow_v4(nft_net(pkt), skb, nft_in(pkt));
|
sk = nf_sk_lookup_slow_v4(nft_net(pkt), skb, nft_in(pkt));
|
||||||
break;
|
break;
|
||||||
#if IS_ENABLED(CONFIG_NF_SOCKET_IPV6)
|
#if IS_ENABLED(CONFIG_NF_TABLES_IPV6)
|
||||||
case NFPROTO_IPV6:
|
case NFPROTO_IPV6:
|
||||||
sk = nf_sk_lookup_slow_v6(nft_net(pkt), skb, nft_in(pkt));
|
sk = nf_sk_lookup_slow_v6(nft_net(pkt), skb, nft_in(pkt));
|
||||||
break;
|
break;
|
||||||
|
@ -77,7 +77,7 @@ static int nft_socket_init(const struct nft_ctx *ctx,
|
||||||
|
|
||||||
switch(ctx->family) {
|
switch(ctx->family) {
|
||||||
case NFPROTO_IPV4:
|
case NFPROTO_IPV4:
|
||||||
#if IS_ENABLED(CONFIG_NF_SOCKET_IPV6)
|
#if IS_ENABLED(CONFIG_NF_TABLES_IPV6)
|
||||||
case NFPROTO_IPV6:
|
case NFPROTO_IPV6:
|
||||||
#endif
|
#endif
|
||||||
case NFPROTO_INET:
|
case NFPROTO_INET:
|
||||||
|
|
|
@ -38,7 +38,7 @@ tee_tg4(struct sk_buff *skb, const struct xt_action_param *par)
|
||||||
return XT_CONTINUE;
|
return XT_CONTINUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if IS_ENABLED(CONFIG_IPV6)
|
#if IS_ENABLED(CONFIG_IP6_NF_IPTABLES)
|
||||||
static unsigned int
|
static unsigned int
|
||||||
tee_tg6(struct sk_buff *skb, const struct xt_action_param *par)
|
tee_tg6(struct sk_buff *skb, const struct xt_action_param *par)
|
||||||
{
|
{
|
||||||
|
@ -141,7 +141,7 @@ static struct xt_target tee_tg_reg[] __read_mostly = {
|
||||||
.destroy = tee_tg_destroy,
|
.destroy = tee_tg_destroy,
|
||||||
.me = THIS_MODULE,
|
.me = THIS_MODULE,
|
||||||
},
|
},
|
||||||
#if IS_ENABLED(CONFIG_IPV6)
|
#if IS_ENABLED(CONFIG_IP6_NF_IPTABLES)
|
||||||
{
|
{
|
||||||
.name = "TEE",
|
.name = "TEE",
|
||||||
.revision = 1,
|
.revision = 1,
|
||||||
|
|
Loading…
Reference in New Issue