Commit 2c8e4372 authored by Herbert Xu's avatar Herbert Xu Committed by Thomas Graf

[IPV6]: Reload skb->dst after xfrm6_route_forward()

While replacing dst_pmtu in ip6_output I found this little gem.  In
ip6_forward we're not reloading the dst pointer after calling
xfrm6_route_forward.  So all subsequent dereferences of dst will
refer to its pre-IPsec value.

The solution is of course to refresh its value.
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 453b6731
...@@ -397,6 +397,7 @@ int ip6_forward(struct sk_buff *skb) ...@@ -397,6 +397,7 @@ int ip6_forward(struct sk_buff *skb)
IP6_INC_STATS(IPSTATS_MIB_INDISCARDS); IP6_INC_STATS(IPSTATS_MIB_INDISCARDS);
goto drop; goto drop;
} }
dst = skb->dst;
/* IPv6 specs say nothing about it, but it is clear that we cannot /* IPv6 specs say nothing about it, but it is clear that we cannot
send redirects to source routed frames. send redirects to source routed frames.
......
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