Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=bee0b40c0621396326d1c17b81833f59118a2d80
Commit:     bee0b40c0621396326d1c17b81833f59118a2d80
Parent:     8bd170750400bfa5e14c3dd2e2d0f305e1ab0e57
Author:     Herbert Xu <[EMAIL PROTECTED]>
AuthorDate: Wed Oct 10 15:42:23 2007 -0700
Committer:  David S. Miller <[EMAIL PROTECTED]>
CommitDate: Wed Oct 10 16:55:53 2007 -0700

    [IPSEC] beet: Fix extension header support on output
    
    The beet output function completely kills any extension headers by replacing
    them with the IPv6 header.  This is because it essentially ignores the
    result of ip6_find_1stfragopt by simply acting as if there aren't any
    extension headers.
    
    Signed-off-by: Herbert Xu <[EMAIL PROTECTED]>
    Signed-off-by: David S. Miller <[EMAIL PROTECTED]>
---
 net/ipv6/xfrm6_mode_beet.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/net/ipv6/xfrm6_mode_beet.c b/net/ipv6/xfrm6_mode_beet.c
index 65e6b2a..d9366df 100644
--- a/net/ipv6/xfrm6_mode_beet.c
+++ b/net/ipv6/xfrm6_mode_beet.c
@@ -44,9 +44,9 @@ static int xfrm6_beet_output(struct xfrm_state *x, struct 
sk_buff *skb)
        hdr_len = ip6_find_1stfragopt(skb, &prevhdr);
        memmove(skb->data, iph, hdr_len);
 
-       skb_set_mac_header(skb, offsetof(struct ipv6hdr, nexthdr));
+       skb_set_mac_header(skb, (prevhdr - x->props.header_len) - skb->data);
        skb_reset_network_header(skb);
-       skb_set_transport_header(skb, sizeof(struct ipv6hdr));
+       skb_set_transport_header(skb, hdr_len);
        top_iph = ipv6_hdr(skb);
 
        ipv6_addr_copy(&top_iph->saddr, (struct in6_addr *)&x->props.saddr);
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to