We cannot use skb->transport_header since it's unset, use
pkt->xt.thoff instead.
Now possible using information made available through the x_tables
compatibility layer.
Reported-by: Eric Leblond <eric@regit.org>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
if (priv->base == NFT_PAYLOAD_NETWORK_HEADER)
ptr = skb_network_header(skb);
else
- ptr = skb_transport_header(skb);
+ ptr = skb_network_header(skb) + pkt->xt.thoff;
ptr += priv->offset;
offset = skb_network_offset(skb);
break;
case NFT_PAYLOAD_TRANSPORT_HEADER:
- offset = skb_transport_offset(skb);
+ offset = pkt->xt.thoff;
break;
default:
BUG();