Skip to content

Commit

Permalink
netfilter: nft_meta: permit pkttype mangling in ip/ip6 prerouting
Browse files Browse the repository at this point in the history
After supporting this, we can combine it with hash expression to emulate
the 'cluster match'.

Suggested-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Liping Zhang <liping.zhang@spreadtrum.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
  • Loading branch information
Liping Zhang authored and Pablo Neira Ayuso committed Oct 26, 2016
1 parent 0ecba4d commit 96d9f2a
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions net/netfilter/nft_meta.c
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,11 @@ int nft_meta_set_validate(const struct nft_ctx *ctx,
case NFPROTO_NETDEV:
hooks = 1 << NF_NETDEV_INGRESS;
break;
case NFPROTO_IPV4:
case NFPROTO_IPV6:
case NFPROTO_INET:
hooks = 1 << NF_INET_PRE_ROUTING;
break;
default:
return -EOPNOTSUPP;
}
Expand Down

0 comments on commit 96d9f2a

Please sign in to comment.