[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20171231074919.otq37lsjlp6xzthi@gauss3.secunet.de>
Date: Sun, 31 Dec 2017 08:49:19 +0100
From: Steffen Klassert <steffen.klassert@...unet.com>
To: Herbert Xu <herbert@...dor.apana.org.au>
CC: <netdev@...r.kernel.org>
Subject: Re: xfrm: Forbid state updates from changing encap type
On Tue, Dec 26, 2017 at 05:34:44PM +1100, Herbert Xu wrote:
> Currently we allow state updates to competely replace the contents
> of x->encap. This is bad because on the user side ESP only sets up
> header lengths depending on encap_type once when the state is first
> created. This could result in the header lengths getting out of
> sync with the actual state configuration.
>
> In practice key managers will never do a state update to change the
> encapsulation type. Only the port numbers need to be changed as the
> peer NAT entry is updated.
>
> Therefore this patch adds a check in xfrm_state_update to forbid
> any changes to the encap_type.
>
> Signed-off-by: Herbert Xu <herbert@...dor.apana.org.au>
Applied to the ipsec tree, thanks Herbert!
Powered by blists - more mailing lists