mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
netfilter: nf_tables: add reject module for NFPROTO_INET
Add a reject module for NFPROTO_INET. It does nothing but dispatch to the AF-specific modules based on the hook family. Signed-off-by: Patrick McHardy <[email protected]> Signed-off-by: Pablo Neira Ayuso <[email protected]>
This commit is contained in:
parent
cc4723ca31
commit
05513e9e33
6 changed files with 85 additions and 6 deletions
|
|
@ -19,9 +19,9 @@
|
|||
#include <net/netfilter/nft_reject.h>
|
||||
#include <net/netfilter/ipv6/nf_reject.h>
|
||||
|
||||
static void nft_reject_ipv6_eval(const struct nft_expr *expr,
|
||||
struct nft_data data[NFT_REG_MAX + 1],
|
||||
const struct nft_pktinfo *pkt)
|
||||
void nft_reject_ipv6_eval(const struct nft_expr *expr,
|
||||
struct nft_data data[NFT_REG_MAX + 1],
|
||||
const struct nft_pktinfo *pkt)
|
||||
{
|
||||
struct nft_reject *priv = nft_expr_priv(expr);
|
||||
struct net *net = dev_net((pkt->in != NULL) ? pkt->in : pkt->out);
|
||||
|
|
@ -38,6 +38,7 @@ static void nft_reject_ipv6_eval(const struct nft_expr *expr,
|
|||
|
||||
data[NFT_REG_VERDICT].verdict = NF_DROP;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(nft_reject_ipv6_eval);
|
||||
|
||||
static struct nft_expr_type nft_reject_ipv6_type;
|
||||
static const struct nft_expr_ops nft_reject_ipv6_ops = {
|
||||
|
|
|
|||
Loading…
Reference in a new issue