Commit 9ff01f5f authored by Bart De Schuymer's avatar Bart De Schuymer Committed by David S. Miller

[ebtables] bugfix in ebt_ip.c

parent b4c81f42
...@@ -86,7 +86,7 @@ static int ebt_ip_check(const char *tablename, unsigned int hookmask, ...@@ -86,7 +86,7 @@ static int ebt_ip_check(const char *tablename, unsigned int hookmask,
if (info->bitmask & ~EBT_IP_MASK || info->invflags & ~EBT_IP_MASK) if (info->bitmask & ~EBT_IP_MASK || info->invflags & ~EBT_IP_MASK)
return -EINVAL; return -EINVAL;
if (info->bitmask & (EBT_IP_DPORT | EBT_IP_SPORT)) { if (info->bitmask & (EBT_IP_DPORT | EBT_IP_SPORT)) {
if (!(info->bitmask & EBT_IPROTO)) if (info->bitmask & EBT_IPROTO)
return -EINVAL; return -EINVAL;
if (info->protocol != IPPROTO_TCP && if (info->protocol != IPPROTO_TCP &&
info->protocol != IPPROTO_UDP) info->protocol != IPPROTO_UDP)
......
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