Skip to contentSkip to conversation

: nf_nat: autoload IPv4 connection tracking

PATCH In review Patrick McHardy 1 participant 1 message Apr 7, 2008

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 2/2 : nf_nat: autoload IPv4 connection tracking

commit 61e0b36c7cf5ef4dd8efe4809d4fe09933ad535f

Author: Jan Engelhardt <[email protected]>
Date:   Mon Apr 7 13:52:15 2008 +0200

[NETFILTER]: nf_nat: autoload IPv4 connection tracking

Without this patch, the generic L3 tracker would kick in if nf_conntrack_ipv4 was not loaded before nf_nat, which would lead to translation problems with ICMP errors.

NAT does not make sense without IPv4 connection tracking anyway, so just add a call to need_ipv4_conntrack().

net/ipv4/netfilter/nf_nat_core.c +2 -0
index 0d5fa3a..36b4e3b 100644
@@ -629,6 +629,8 @@ static int __init nf_nat_init(void)
 	size_t i;
 	int ret;
 
+	need_ipv4_conntrack();
+
 	ret = nf_ct_extend_register(&nat_extend);
 	if (ret < 0) {
 		printk(KERN_ERR "nf_nat_core: Unable to register extension\n");