Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

netfilter: x_tables: add module alias for icmp matches

The icmp matches are implemented in ip_tables and ip6_tables,
respectively, so for normal iptables they are always available:
those modules are loaded once iptables calls getsockopt() to fetch
available module revisions.

In iptables-over-nftables case probing occurs via nfnetlink, so
these modules might not be loaded. Add aliases so modprobe can load
these when icmp/icmp6 is requested.

Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>

authored by

Florian Westphal and committed by
Pablo Neira Ayuso
a44f6d82 4e09fc87

+2
+1
net/ipv4/netfilter/ip_tables.c
··· 34 34 MODULE_LICENSE("GPL"); 35 35 MODULE_AUTHOR("Netfilter Core Team <coreteam@netfilter.org>"); 36 36 MODULE_DESCRIPTION("IPv4 packet filter"); 37 + MODULE_ALIAS("ipt_icmp"); 37 38 38 39 void *ipt_alloc_initial_table(const struct xt_table *info) 39 40 {
+1
net/ipv6/netfilter/ip6_tables.c
··· 38 38 MODULE_LICENSE("GPL"); 39 39 MODULE_AUTHOR("Netfilter Core Team <coreteam@netfilter.org>"); 40 40 MODULE_DESCRIPTION("IPv6 packet filter"); 41 + MODULE_ALIAS("ip6t_icmp6"); 41 42 42 43 void *ip6t_alloc_initial_table(const struct xt_table *info) 43 44 {