lkml.org 
[lkml]   [2019]   [Aug]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v3 1/2] fork: extend clone3() to support CLONE_SET_TID
On 08/06, Adrian Reber wrote:
>
> @@ -2573,6 +2575,14 @@ noinline static int copy_clone_args_from_user(struct kernel_clone_args *kargs,
> .tls = args.tls,
> };
>
> + if (size == sizeof(struct clone_args)) {
> + /* Only check permissions if set_tid is actually set. */
> + if (args.set_tid &&
> + !ns_capable(pid_ns->user_ns, CAP_SYS_ADMIN))

and I just noticed this uses pid_ns = task_active_pid_ns() ...

is it correct?

I feel I am totally confused, but should we use the same
p->nsproxy->pid_ns_for_children passed to alloc_pid?

Oleg.

\
 
 \ /
  Last update: 2019-08-07 18:09    [W:0.083 / U:0.160 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site