Commit 97c802a1 authored by Phil Oester's avatar Phil Oester Committed by David S. Miller

[NETFILTER]: xt_string: fix negation

The xt_string match is broken with ! negation.
This resolves a portion of netfilter bugzilla #497.
Signed-off-by: default avatarPhil Oester <kernel@linuxace.com>
Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 18b6fe64
...@@ -37,7 +37,7 @@ static int match(const struct sk_buff *skb, ...@@ -37,7 +37,7 @@ static int match(const struct sk_buff *skb,
return (skb_find_text((struct sk_buff *)skb, conf->from_offset, return (skb_find_text((struct sk_buff *)skb, conf->from_offset,
conf->to_offset, conf->config, &state) conf->to_offset, conf->config, &state)
!= UINT_MAX) && !conf->invert; != UINT_MAX) ^ conf->invert;
} }
#define STRING_TEXT_PRIV(m) ((struct xt_string_info *) m) #define STRING_TEXT_PRIV(m) ((struct xt_string_info *) m)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment