Commit a8d0f952 authored by Patrick McHardy's avatar Patrick McHardy Committed by David S. Miller

[NET]: Add UDPLITE support in a few missing spots

Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 5eb87f45
...@@ -93,6 +93,7 @@ static int ebt_ip_check(const char *tablename, unsigned int hookmask, ...@@ -93,6 +93,7 @@ static int ebt_ip_check(const char *tablename, unsigned int hookmask,
return -EINVAL; return -EINVAL;
if (info->protocol != IPPROTO_TCP && if (info->protocol != IPPROTO_TCP &&
info->protocol != IPPROTO_UDP && info->protocol != IPPROTO_UDP &&
info->protocol != IPPROTO_UDPLITE &&
info->protocol != IPPROTO_SCTP && info->protocol != IPPROTO_SCTP &&
info->protocol != IPPROTO_DCCP) info->protocol != IPPROTO_DCCP)
return -EINVAL; return -EINVAL;
......
...@@ -96,6 +96,7 @@ ebt_log_packet(unsigned int pf, unsigned int hooknum, ...@@ -96,6 +96,7 @@ ebt_log_packet(unsigned int pf, unsigned int hooknum,
NIPQUAD(ih->daddr), ih->tos, ih->protocol); NIPQUAD(ih->daddr), ih->tos, ih->protocol);
if (ih->protocol == IPPROTO_TCP || if (ih->protocol == IPPROTO_TCP ||
ih->protocol == IPPROTO_UDP || ih->protocol == IPPROTO_UDP ||
ih->protocol == IPPROTO_UDPLITE ||
ih->protocol == IPPROTO_SCTP || ih->protocol == IPPROTO_SCTP ||
ih->protocol == IPPROTO_DCCP) { ih->protocol == IPPROTO_DCCP) {
struct tcpudphdr _ports, *pptr; struct tcpudphdr _ports, *pptr;
......
...@@ -247,6 +247,7 @@ clusterip_hashfn(struct sk_buff *skb, struct clusterip_config *config) ...@@ -247,6 +247,7 @@ clusterip_hashfn(struct sk_buff *skb, struct clusterip_config *config)
switch (iph->protocol) { switch (iph->protocol) {
case IPPROTO_TCP: case IPPROTO_TCP:
case IPPROTO_UDP: case IPPROTO_UDP:
case IPPROTO_UDPLITE:
case IPPROTO_SCTP: case IPPROTO_SCTP:
case IPPROTO_DCCP: case IPPROTO_DCCP:
case IPPROTO_ICMP: case IPPROTO_ICMP:
......
...@@ -414,6 +414,7 @@ hashlimit_init_dst(struct xt_hashlimit_htable *hinfo, struct dsthash_dst *dst, ...@@ -414,6 +414,7 @@ hashlimit_init_dst(struct xt_hashlimit_htable *hinfo, struct dsthash_dst *dst,
switch (nexthdr) { switch (nexthdr) {
case IPPROTO_TCP: case IPPROTO_TCP:
case IPPROTO_UDP: case IPPROTO_UDP:
case IPPROTO_UDPLITE:
case IPPROTO_SCTP: case IPPROTO_SCTP:
case IPPROTO_DCCP: case IPPROTO_DCCP:
ports = skb_header_pointer(skb, protoff, sizeof(_ports), ports = skb_header_pointer(skb, protoff, sizeof(_ports),
......
...@@ -143,6 +143,7 @@ static unsigned sfq_hash(struct sfq_sched_data *q, struct sk_buff *skb) ...@@ -143,6 +143,7 @@ static unsigned sfq_hash(struct sfq_sched_data *q, struct sk_buff *skb)
if (!(iph->frag_off&htons(IP_MF|IP_OFFSET)) && if (!(iph->frag_off&htons(IP_MF|IP_OFFSET)) &&
(iph->protocol == IPPROTO_TCP || (iph->protocol == IPPROTO_TCP ||
iph->protocol == IPPROTO_UDP || iph->protocol == IPPROTO_UDP ||
iph->protocol == IPPROTO_UDPLITE ||
iph->protocol == IPPROTO_SCTP || iph->protocol == IPPROTO_SCTP ||
iph->protocol == IPPROTO_DCCP || iph->protocol == IPPROTO_DCCP ||
iph->protocol == IPPROTO_ESP)) iph->protocol == IPPROTO_ESP))
...@@ -156,6 +157,7 @@ static unsigned sfq_hash(struct sfq_sched_data *q, struct sk_buff *skb) ...@@ -156,6 +157,7 @@ static unsigned sfq_hash(struct sfq_sched_data *q, struct sk_buff *skb)
h2 = iph->saddr.s6_addr32[3]^iph->nexthdr; h2 = iph->saddr.s6_addr32[3]^iph->nexthdr;
if (iph->nexthdr == IPPROTO_TCP || if (iph->nexthdr == IPPROTO_TCP ||
iph->nexthdr == IPPROTO_UDP || iph->nexthdr == IPPROTO_UDP ||
iph->nexthdr == IPPROTO_UDPLITE ||
iph->nexthdr == IPPROTO_SCTP || iph->nexthdr == IPPROTO_SCTP ||
iph->nexthdr == IPPROTO_DCCP || iph->nexthdr == IPPROTO_DCCP ||
iph->nexthdr == IPPROTO_ESP) iph->nexthdr == IPPROTO_ESP)
......
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