RE: [PATCH v2] scm: fix possible control message header alignment issue

2017-01-02 Thread YUAN Linyu
> -Original Message- > From: David Miller [mailto:da...@davemloft.net] > Sent: Saturday, December 31, 2016 4:21 AM > To: cug...@163.com > Cc: netdev@vger.kernel.org; YUAN Linyu > Subject: Re: [PATCH v2] scm: fix possible control message header alignment > issue >

Re: [PATCH v2] scm: fix possible control message header alignment issue

2016-12-30 Thread David Miller
From: yuan linyu Date: Thu, 29 Dec 2016 20:39:32 +0800 > From: yuan linyu > > 1. put_cmsg{_compat}() may copy data to user when buffer free space less than >control message header alignment size. > 2. scm_detach_fds{_compat}() may calc wrong fdmax if control message header >have greater

[PATCH v2] scm: fix possible control message header alignment issue

2016-12-29 Thread yuan linyu
From: yuan linyu 1. put_cmsg{_compat}() may copy data to user when buffer free space less than control message header alignment size. 2. scm_detach_fds{_compat}() may calc wrong fdmax if control message header have greater alignment size. Signed-off-by: yuan linyu --- net/compat.c | 10