xt_length2: IPv6 jumbogram support

This commit is contained in:
Jan Engelhardt
2010-07-24 10:57:03 +02:00
parent 6dedbef3d4
commit 4d48511f01
2 changed files with 6 additions and 1 deletions

View File

@@ -207,7 +207,11 @@ length2_mt6(const struct sk_buff *skb, struct xt_action_param *par)
bool hit = true;
if (info->flags & XT_LENGTH_LAYER3) {
len = sizeof(struct ipv6hdr) + ntohs(iph->payload_len);
if (iph->payload_len == 0)
/* Jumbogram */
len = skb->len;
else
len = sizeof(struct ipv6hdr) + ntohs(iph->payload_len);
} else {
l4proto = llayer4_proto(skb, &thoff, &par->hotdrop);
if (l4proto == NEXTHDR_MAX)