Re: [PATCH v6 1/7] net/scm: Regularize compat handling of scm_detach_fds()

2020-07-08 Thread Kees Cook
On Tue, Jul 07, 2020 at 01:41:03PM +0200, Christian Brauner wrote: > On Mon, Jul 06, 2020 at 01:17:14PM -0700, Kees Cook wrote: > > Duplicate the cleanups from commit 2618d530dd8b ("net/scm: cleanup > > scm_detach_fds") into the compat code. > > > > Move the check added in commit 1f466e1f15cf ("ne

Re: [PATCH v6 1/7] net/scm: Regularize compat handling of scm_detach_fds()

2020-07-07 Thread Christian Brauner
On Mon, Jul 06, 2020 at 01:17:14PM -0700, Kees Cook wrote: > Duplicate the cleanups from commit 2618d530dd8b ("net/scm: cleanup > scm_detach_fds") into the compat code. > > Move the check added in commit 1f466e1f15cf ("net: cleanly handle kernel > vs user buffers for ->msg_control") to before the

[PATCH v6 1/7] net/scm: Regularize compat handling of scm_detach_fds()

2020-07-06 Thread Kees Cook
Duplicate the cleanups from commit 2618d530dd8b ("net/scm: cleanup scm_detach_fds") into the compat code. Move the check added in commit 1f466e1f15cf ("net: cleanly handle kernel vs user buffers for ->msg_control") to before the compat call, even though it should be impossible for an in-kernel cal