Subject: Re: [PATCH net-next] xfrm: Correctly parse netlink msg from 32bits ip command on 64bits host

From: Steffen Klassert <[email-masked]>
Date: Tue, 25 Feb 2014 12:53:39 +0100

On Tue, Feb 25, 2014 at 02:41:11PM +0800, Fan Du wrote:
> 
> 
> On 2014年02月20日 17:59, Steffen Klassert wrote:
> >For now I think we should just refuse to do anything if someone tries
> >to configure ipsec with 32 bit tools on a 64 bit machine.
> 
> I'm fine with your point, and it would be a good choice to inform user about
> this behavior other than just creating non-working SA and SP for user.
> 
> 
> From 873812ec0fe8738f476de58a217e58ec47665180 Mon Sep 17 00:00:00 2001
> From: Fan Du <[email-masked]>
> Date: Tue, 25 Feb 2014 14:34:41 +0800
> Subject: [PATCH net-next] xfrm: Do not parse 32bits compiled xfrm netlink msg on
>  64bits host
> 
> structure like xfrm_usersa_info or xfrm_userpolicy_info has different sizeof
> when compiled as 32bits and 64bits due to not appending pack attribute in
> their definition. This will result in broken SA and SP information when user
> trying to configure them through netlink interface.
> 
> Before forging a compatibility layer like we have it for system calls to map
> this correct. Inform user land about this situation instead of keeping silent,
> then the upper test scripts could behave accordingly.
> 
> Signed-off-by: Fan Du <[email-masked]>

I'm ok with your patch, but it does not apply to ipsec-next.
Please rebase to ipsec-next current and resend.

Thanks!