提交 253aa115 编写于 作者: D David S. Miller

[IPSEC] xfrm_user: Kill PAGE_SIZE check in verify_sec_ctx_len()

First, it warns when PAGE_SIZE >= 64K because the ctx_len
field is 16-bits.

Secondly, if there are any real length limitations it can
be verified by the security layer security_xfrm_state_alloc()
call.
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 50bf3e22
......@@ -101,9 +101,6 @@ static inline int verify_sec_ctx_len(struct rtattr **xfrma)
uctx = RTA_DATA(rt);
if (uctx->ctx_len > PAGE_SIZE)
return -EINVAL;
len += sizeof(struct xfrm_user_sec_ctx);
len += uctx->ctx_len;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册