X-Git-Url: http://pilppa.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=net%2Fipv6%2Fesp6.c;h=b181b08fb761c4f9cab3e4f06dfc439734213298;hb=810ad7b62c0f075dc44ecc781b24c7f6ba388da5;hp=c6bb4c6d24b38352b4430e7892b59068714a9b3e;hpb=adf6d34e460387ee3e8f1e1875d52bff51212c7d;p=linux-2.6-omap-h63xx.git diff --git a/net/ipv6/esp6.c b/net/ipv6/esp6.c index c6bb4c6d24b..b181b08fb76 100644 --- a/net/ipv6/esp6.c +++ b/net/ipv6/esp6.c @@ -521,6 +521,10 @@ static int esp6_init_state(struct xfrm_state *x) crypto_aead_ivsize(aead); switch (x->props.mode) { case XFRM_MODE_BEET: + if (x->sel.family != AF_INET6) + x->props.header_len += IPV4_BEET_PHMAXLEN + + (sizeof(struct ipv6hdr) - sizeof(struct iphdr)); + break; case XFRM_MODE_TRANSPORT: break; case XFRM_MODE_TUNNEL: