lkml.org 
[lkml]   [2021]   [Dec]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] exit: Retain nsproxy for exit_task_work() work entries
On Thu, Dec 09, 2021 at 02:44:19PM +0100, Michal Koutný wrote:
> On Wed, Dec 08, 2021 at 01:07:54PM -1000, Tejun Heo <tj@kernel.org> wrote:
>
> > + saved_cred = override_creds(of->file->f_cred);
> > ret = cgroup_attach_permissions(src_cgrp, dst_cgrp,
> > - of->file->f_path.dentry->d_sb, threadgroup);
> > + of->file->f_path.dentry->d_sb,
> > + threadgroup, ctx->ns);
> > + revert_creds(saved_cred);
>
> I wonder now whether such a wrap shouldn't also be around cgroup_kill()
> too (+ replacement of send_sig() with group_send_sig_info() [1])?

send_sig() isn't used that was changed in response to a review. I'm
confused.

>
> This shouldn't break the use case of passing cgroup kill fd to a less
> privileged task for (auto)destruction purposes but on the other hand it
> would prevent subverting the fd to a more privileged confused task to
> kill otherwise disallowed processes.

Kill and freeze only do time permission checking at open. Why would you
introduce another write time check?

\
 
 \ /
  Last update: 2021-12-09 15:09    [W:0.043 / U:1.104 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site