netfilter: add bpf match support
authorAlin Nastac <alin.nastac@gmail.com>
Mon, 25 Jun 2018 08:22:21 +0000 (10:22 +0200)
committerJohn Crispin <john@phrozen.org>
Tue, 26 Jun 2018 06:57:25 +0000 (08:57 +0200)
Add xt_bpf modules to {kmod-ipt,iptables-mod}-filter.

Match using Linux Socket Filter. Expects a BPF program in decimal
format. This is the format generated by the nfbpf_compile utility.

Signed-off-by: Alin Nastac <alin.nastac@gmail.com>
include/netfilter.mk
package/kernel/linux/modules/netfilter.mk
package/network/utils/iptables/Makefile

index 5d532ce..510aa18 100644 (file)
@@ -106,6 +106,7 @@ $(eval $(call nf_add,IPT_PHYSDEV,CONFIG_NETFILTER_XT_MATCH_PHYSDEV, $(P_XT)xt_ph
 # filter
 
 $(eval $(call nf_add,IPT_FILTER,CONFIG_NETFILTER_XT_MATCH_STRING, $(P_XT)xt_string))
+$(eval $(call nf_add,IPT_FILTER,CONFIG_NETFILTER_XT_MATCH_BPF, $(P_XT)xt_bpf))
 
 
 # ipopt
index 51f3544..be469fa 100644 (file)
@@ -237,6 +237,7 @@ define KernelPackage/ipt-filter/description
  Netfilter (IPv4) kernel modules for packet content inspection
  Includes:
  - string
+ - bpf
 endef
 
 $(eval $(call KernelPackage,ipt-filter))
index b3955b9..8423701 100644 (file)
@@ -151,6 +151,7 @@ Includes support for:
 
  Matches:
   - string
+  - bpf
 
 endef