Skip to content
Commit c9f3f813 authored by Steffen Klassert's avatar Steffen Klassert
Browse files

xfrm: Fix stack-out-of-bounds read in xfrm_state_find.



When we do tunnel or beet mode, we pass saddr and daddr from the
template to xfrm_state_find(), this is ok. On transport mode,
we pass the addresses from the flowi, assuming that the IP
addresses (and address family) don't change during transformation.
This assumption is wrong in the IPv4 mapped IPv6 case, packet
is IPv4 and template is IPv6. Fix this by using the addresses
from the template unconditionally.

Signed-off-by: default avatarSteffen Klassert <steffen.klassert@secunet.com>
parent cf379667
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment