]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
Fix NAT of ICMP ID ranges (Patrick McHardy)
authorPatrick McHardy <kaber@trash.net>
Fri, 22 Jul 2005 06:39:45 +0000 (06:39 +0000)
committerHarald Welte <laforge@gnumonks.org>
Fri, 22 Jul 2005 06:39:45 +0000 (06:39 +0000)
extensions/libipt_DNAT.c
extensions/libipt_MASQUERADE.c
extensions/libipt_REDIRECT.c
extensions/libipt_SNAT.c

index 9e4f525355f84f5745c69abb8863d452c151310b..3b0d146c18fa911a4f356ab636ffee5f56223b18 100644 (file)
@@ -143,7 +143,8 @@ parse(int c, char **argv, int invert, unsigned int *flags,
        int portok;
 
        if (entry->ip.proto == IPPROTO_TCP
-           || entry->ip.proto == IPPROTO_UDP)
+           || entry->ip.proto == IPPROTO_UDP
+           || entry->ip.proto == IPPROTO_ICMP)
                portok = 1;
        else
                portok = 0;
index b661012e7f55949afacc507bb50ac7b106c27264..7eddcc09bbd317a9c551b245636a8a0217378a4f 100644 (file)
@@ -81,7 +81,8 @@ parse(int c, char **argv, int invert, unsigned int *flags,
                = (struct ip_nat_multi_range *)(*target)->data;
 
        if (entry->ip.proto == IPPROTO_TCP
-           || entry->ip.proto == IPPROTO_UDP)
+           || entry->ip.proto == IPPROTO_UDP
+           || entry->ip.proto == IPPROTO_ICMP)
                portok = 1;
        else
                portok = 0;
index 1395f62ea0b95cd9d0d4c2d546cff5bb05738204..e29bf2ff7b6fc205252410b78e50852d3c7113c5 100644 (file)
@@ -81,7 +81,8 @@ parse(int c, char **argv, int invert, unsigned int *flags,
        int portok;
 
        if (entry->ip.proto == IPPROTO_TCP
-           || entry->ip.proto == IPPROTO_UDP)
+           || entry->ip.proto == IPPROTO_UDP
+           || entry->ip.proto == IPPROTO_ICMP)
                portok = 1;
        else
                portok = 0;
index a893a47d1a5ddf221b0b3367383b9a26c08a8b2d..746076031e63ee09cc5e2b563680fd632322e9ea 100644 (file)
@@ -143,7 +143,8 @@ parse(int c, char **argv, int invert, unsigned int *flags,
        int portok;
 
        if (entry->ip.proto == IPPROTO_TCP
-           || entry->ip.proto == IPPROTO_UDP)
+           || entry->ip.proto == IPPROTO_UDP
+           || entry->ip.proto == IPPROTO_ICMP)
                portok = 1;
        else
                portok = 0;