Skip to content

Commit

Permalink
[NETFILTER]: nf_nat: autoload IPv4 connection tracking
Browse files Browse the repository at this point in the history
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().

Signed-off-by: Jan Engelhardt <jengelh@computergmbh.de>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Jan Engelhardt authored and David S. Miller committed Apr 9, 2008
1 parent 1b9b70e commit 475959d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions net/ipv4/netfilter/nf_nat_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -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");
Expand Down

0 comments on commit 475959d

Please sign in to comment.