diff options
author | Lin Ma <linma@zju.edu.cn> | 2023-06-30 16:19:11 +0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2023-08-23 17:52:32 +0200 |
commit | 71dfe71df100fa807660fa16f4a0a66cffeb7f46 (patch) | |
tree | c9c710a6367b12e7d4600813a52167916eba5bb4 /net/psample/psample.c | |
parent | 479884b4ce16ea6a4cc5a4392f8d778616db9e26 (diff) | |
download | linux-71dfe71df100fa807660fa16f4a0a66cffeb7f46.tar.gz |
net: xfrm: Amend XFRMA_SEC_CTX nla_policy structure
[ Upstream commit d1e0e61d617ba17aa516db707aa871387566bbf7 ] According to all consumers code of attrs[XFRMA_SEC_CTX], like * verify_sec_ctx_len(), convert to xfrm_user_sec_ctx* * xfrm_state_construct(), call security_xfrm_state_alloc whose prototype is int security_xfrm_state_alloc(.., struct xfrm_user_sec_ctx *sec_ctx); * copy_from_user_sec_ctx(), convert to xfrm_user_sec_ctx * ... It seems that the expected parsing result for XFRMA_SEC_CTX should be structure xfrm_user_sec_ctx, and the current xfrm_sec_ctx is confusing and misleading (Luckily, they happen to have same size 8 bytes). This commit amend the policy structure to xfrm_user_sec_ctx to avoid ambiguity. Fixes: cf5cb79f6946 ("[XFRM] netlink: Establish an attribute policy") Signed-off-by: Lin Ma <linma@zju.edu.cn> Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'net/psample/psample.c')
0 files changed, 0 insertions, 0 deletions