Re: [PATCH] sysctl: Delete the code of sys_sysctl

2020-06-10 Thread Kees Cook
On Wed, Jun 10, 2020 at 10:17:49PM +0800, Xiaoming Ni wrote: > On 2020/6/9 23:40, Kees Cook wrote: > > On Tue, Jun 09, 2020 at 02:20:05PM +0800, Xiaoming Ni wrote: > > > Since the commit 61a47c1ad3a4dc ("sysctl: Remove the sysctl system call"), > > > sys_sysctl has lost its actual role: any input c

Re: [PATCH] sysctl: Delete the code of sys_sysctl

2020-06-10 Thread Xiaoming Ni
On 2020/6/10 3:20, Eric W. Biederman wrote: Xiaoming Ni writes: Since the commit 61a47c1ad3a4dc ("sysctl: Remove the sysctl system call"), sys_sysctl has lost its actual role: any input can only return an error. The remaining code does have a role. It reports programs that attempt to use th

Re: [PATCH] sysctl: Delete the code of sys_sysctl

2020-06-10 Thread Xiaoming Ni
On 2020/6/9 23:40, Kees Cook wrote: On Tue, Jun 09, 2020 at 02:20:05PM +0800, Xiaoming Ni wrote: Since the commit 61a47c1ad3a4dc ("sysctl: Remove the sysctl system call"), sys_sysctl has lost its actual role: any input can only return an error. Delete the code and return -ENOSYS directly at the

Re: [PATCH] sysctl: Delete the code of sys_sysctl

2020-06-09 Thread Eric W. Biederman
Xiaoming Ni writes: > Since the commit 61a47c1ad3a4dc ("sysctl: Remove the sysctl system call"), > sys_sysctl has lost its actual role: any input can only return an error. The remaining code does have a role. It reports programs that attempt to use the removed sysctl. It would help if your cha

Re: [PATCH] sysctl: Delete the code of sys_sysctl

2020-06-09 Thread Kees Cook
On Tue, Jun 09, 2020 at 02:20:05PM +0800, Xiaoming Ni wrote: > Since the commit 61a47c1ad3a4dc ("sysctl: Remove the sysctl system call"), > sys_sysctl has lost its actual role: any input can only return an error. > > Delete the code and return -ENOSYS directly at the function entry > > Signed-off

[PATCH] sysctl: Delete the code of sys_sysctl

2020-06-08 Thread Xiaoming Ni
Since the commit 61a47c1ad3a4dc ("sysctl: Remove the sysctl system call"), sys_sysctl has lost its actual role: any input can only return an error. Delete the code and return -ENOSYS directly at the function entry Signed-off-by: Xiaoming Ni --- kernel/sysctl_binary.c | 146 +