diff options
author | Jan Engelhardt <jengelh@computergmbh.de> | 2008-02-27 12:20:41 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-02-27 12:20:41 -0800 |
commit | 6556874dc3770aefae89907b3cf9be8e23d66137 (patch) | |
tree | 9a3d635a5ceb0672858eb4cbecdc13a3e075c599 /net | |
parent | d61f89e9417e68caf9ca801606694c1c960ad179 (diff) | |
download | linux-6556874dc3770aefae89907b3cf9be8e23d66137.tar.bz2 |
[NETFILTER]: xt_conntrack: fix IPv4 address comparison
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>
Diffstat (limited to 'net')
-rw-r--r-- | net/netfilter/xt_conntrack.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/netfilter/xt_conntrack.c b/net/netfilter/xt_conntrack.c index dd192ac74b4a..0c50b2894055 100644 --- a/net/netfilter/xt_conntrack.c +++ b/net/netfilter/xt_conntrack.c @@ -122,7 +122,7 @@ conntrack_addrcmp(const union nf_inet_addr *kaddr, const union nf_inet_addr *umask, unsigned int l3proto) { if (l3proto == AF_INET) - return (kaddr->ip & umask->ip) == uaddr->ip; + return ((kaddr->ip ^ uaddr->ip) & umask->ip) == 0; else if (l3proto == AF_INET6) return ipv6_masked_addr_cmp(&kaddr->in6, &umask->in6, &uaddr->in6) == 0; |