[lkml]   [2017]   [Nov]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH v5 next 0/5] Improve Module autoloading infrastructure
On Mon, 27 Nov 2017, Kees Cook wrote:

> > if (WARN_ON_ONCE(!capable(CAP_SYS_MODULE) ||
> > !capable(CAP_SYS_ADMIN) ||
> > !capable(CAP_NET_ADMIN) ||
> > !unprivileged_autoload(module_name)))

(Side note: the capable() calls would ideally come after the whitelist

> We have some of this already with the module prefixes. Doing this
> per-module would need to be exported to userspace, I think. It'd be
> way too fragile sitting in the kernel.

What about writing a whitelist to /proc (per-task) or /sys/fs (global) ?

The per-task whitelist is inherited from the global one by default, or
from a parent process if it's been modified in the parent.

James Morris

 \ /
  Last update: 2017-11-28 00:47    [W:0.092 / U:2.248 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site