All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andy Lutomirski <luto@amacapital.net>
To: Kees Cook <keescook@chromium.org>
Cc: Djalal Harouni <tixxdz@gmail.com>,
	Linux API <linux-api@vger.kernel.org>,
	"kernel-hardening@lists.openwall.com" 
	<kernel-hardening@lists.openwall.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Lafcadio Wluiki <wluikil@gmail.com>
Subject: Re: [PATCH v4 2/2] procfs/tasks: add a simple per-task procfs hidepid= field
Date: Mon, 13 Feb 2017 11:01:44 -0800	[thread overview]
Message-ID: <CALCETrWNY9Ea=3dKksFJjizoH5eZbVOFWFnWoJrCRwP0R1QWHg@mail.gmail.com> (raw)
In-Reply-To: <CAGXu5jKz5vo3NwKb_JmNyWDCP0izK=sxTL6Dx_KmYX=1NK+icA@mail.gmail.com>

On Fri, Feb 10, 2017 at 3:44 PM, Kees Cook <keescook@chromium.org> wrote:
> On Wed, Jan 18, 2017 at 3:35 PM, Andy Lutomirski <luto@amacapital.net> wrote:
>> On Wed, Jan 18, 2017 at 2:50 PM, Djalal Harouni <tixxdz@gmail.com> wrote:
>>> Andy I don't follow here, no_new_privs is never cleared right ? I
>>> can't see the corresponding clear bit code for it.
>>
>> I believe that unsharing userns clears no_new_privs.
>
> Seriously? That's kind of ... weird. I mean, I guess you're
> priv-confined in a way, but that seems fragile.
>

I appear to have made this up.  Either I genuinely pulled it out of
thin air or it was discussed and not done.

$ setpriv --nnp unshare -Ur cat /proc/self/status |grep NoNewPrivs
NoNewPrivs:    1

If it were to be done, it ought to be quite safe except for possible LSM issues.

--Andy

WARNING: multiple messages have this Message-ID (diff)
From: Andy Lutomirski <luto@amacapital.net>
To: Kees Cook <keescook@chromium.org>
Cc: Djalal Harouni <tixxdz@gmail.com>,
	Linux API <linux-api@vger.kernel.org>,
	"kernel-hardening@lists.openwall.com"
	<kernel-hardening@lists.openwall.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Lafcadio Wluiki <wluikil@gmail.com>
Subject: [kernel-hardening] Re: [PATCH v4 2/2] procfs/tasks: add a simple per-task procfs hidepid= field
Date: Mon, 13 Feb 2017 11:01:44 -0800	[thread overview]
Message-ID: <CALCETrWNY9Ea=3dKksFJjizoH5eZbVOFWFnWoJrCRwP0R1QWHg@mail.gmail.com> (raw)
In-Reply-To: <CAGXu5jKz5vo3NwKb_JmNyWDCP0izK=sxTL6Dx_KmYX=1NK+icA@mail.gmail.com>

On Fri, Feb 10, 2017 at 3:44 PM, Kees Cook <keescook@chromium.org> wrote:
> On Wed, Jan 18, 2017 at 3:35 PM, Andy Lutomirski <luto@amacapital.net> wrote:
>> On Wed, Jan 18, 2017 at 2:50 PM, Djalal Harouni <tixxdz@gmail.com> wrote:
>>> Andy I don't follow here, no_new_privs is never cleared right ? I
>>> can't see the corresponding clear bit code for it.
>>
>> I believe that unsharing userns clears no_new_privs.
>
> Seriously? That's kind of ... weird. I mean, I guess you're
> priv-confined in a way, but that seems fragile.
>

I appear to have made this up.  Either I genuinely pulled it out of
thin air or it was discussed and not done.

$ setpriv --nnp unshare -Ur cat /proc/self/status |grep NoNewPrivs
NoNewPrivs:    1

If it were to be done, it ought to be quite safe except for possible LSM issues.

--Andy

  reply	other threads:[~2017-02-13 19:02 UTC|newest]

Thread overview: 68+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-16 13:23 [PATCH v4 0/2] procfs/tasks: introduce per-task procfs hidepid= field Djalal Harouni
2017-01-16 13:23 ` [kernel-hardening] " Djalal Harouni
2017-01-16 13:23 ` [PATCH v4 1/2] procfs: use an enum for possible hidepid values Djalal Harouni
2017-01-16 13:23   ` [kernel-hardening] " Djalal Harouni
2017-02-13 22:16   ` Kees Cook
2017-02-13 22:16     ` [kernel-hardening] " Kees Cook
2017-02-15  0:34     ` Andrew Morton
2017-02-15  0:34       ` [kernel-hardening] " Andrew Morton
2017-02-15  8:56       ` Djalal Harouni
2017-02-15  8:56         ` [kernel-hardening] " Djalal Harouni
2017-01-16 13:23 ` [PATCH v4 2/2] procfs/tasks: add a simple per-task procfs hidepid= field Djalal Harouni
2017-01-16 13:23   ` [kernel-hardening] " Djalal Harouni
2017-01-16 17:12   ` Djalal Harouni
2017-01-16 17:12     ` [kernel-hardening] " Djalal Harouni
     [not found]   ` <1484572984-13388-3-git-send-email-djalal-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2017-01-16 17:15     ` Djalal Harouni
     [not found]       ` <CAEiveUfDvSoW9Hy2Y_uxU2YQ+vR8OvXMqRhxAANTGG7QaQbJeg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-01-17 20:33         ` Andy Lutomirski
2017-01-18 22:50           ` Djalal Harouni
2017-01-18 22:50             ` [kernel-hardening] " Djalal Harouni
2017-01-18 23:35             ` Andy Lutomirski
2017-01-18 23:35               ` [kernel-hardening] " Andy Lutomirski
2017-01-18 23:35               ` Andy Lutomirski
2017-01-19 13:53               ` Djalal Harouni
2017-01-19 13:53                 ` [kernel-hardening] " Djalal Harouni
2017-01-19 13:53                 ` Djalal Harouni
2017-01-19 19:52                 ` Andy Lutomirski
2017-01-19 19:52                   ` [kernel-hardening] " Andy Lutomirski
2017-01-19 19:52                   ` Andy Lutomirski
2017-01-20 15:56                   ` Lafcadio Wluiki
2017-01-20 15:56                     ` [kernel-hardening] " Lafcadio Wluiki
2017-01-20 15:56                     ` Lafcadio Wluiki
2017-01-20 16:33                   ` Djalal Harouni
2017-01-20 16:33                     ` [kernel-hardening] " Djalal Harouni
2017-01-20 16:33                     ` Djalal Harouni
2017-01-21  0:53                     ` Andy Lutomirski
2017-01-21  0:53                       ` [kernel-hardening] " Andy Lutomirski
2017-01-21  0:53                       ` Andy Lutomirski
2017-01-23 11:46                       ` Djalal Harouni
2017-01-23 11:46                         ` [kernel-hardening] " Djalal Harouni
2017-01-23 11:46                         ` Djalal Harouni
2017-01-23 20:07                         ` Andy Lutomirski
2017-01-23 20:07                           ` [kernel-hardening] " Andy Lutomirski
2017-01-23 20:07                           ` Andy Lutomirski
2017-01-26 13:20                           ` Djalal Harouni
2017-01-26 13:20                             ` [kernel-hardening] " Djalal Harouni
2017-01-26 13:20                             ` Djalal Harouni
2017-02-10 14:40                       ` Lafcadio Wluiki
2017-02-10 14:40                         ` [kernel-hardening] " Lafcadio Wluiki
2017-02-10 14:40                         ` Lafcadio Wluiki
2017-02-10 16:18                         ` Andy Lutomirski
2017-02-10 16:18                           ` [kernel-hardening] " Andy Lutomirski
2017-02-10 16:18                           ` Andy Lutomirski
2017-01-20 15:44               ` Lafcadio Wluiki
2017-01-20 15:44                 ` [kernel-hardening] " Lafcadio Wluiki
2017-01-20 15:44                 ` Lafcadio Wluiki
2017-02-10 23:44               ` Kees Cook
2017-02-10 23:44                 ` [kernel-hardening] " Kees Cook
2017-02-10 23:44                 ` Kees Cook
2017-02-13 19:01                 ` Andy Lutomirski [this message]
2017-02-13 19:01                   ` [kernel-hardening] " Andy Lutomirski
2017-02-13 19:01                   ` Andy Lutomirski
2017-02-13 19:15                   ` Kees Cook
2017-02-13 19:15                     ` [kernel-hardening] " Kees Cook
2017-02-13 19:15                     ` Kees Cook
2017-02-14  4:11                     ` Christian Kujau
2017-02-14  4:11                       ` [kernel-hardening] " Christian Kujau
2017-02-14  4:11                       ` Christian Kujau
2017-01-16 18:24   ` [kernel-hardening] " Daniel Micay
2017-01-17  9:54     ` Lafcadio Wluiki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CALCETrWNY9Ea=3dKksFJjizoH5eZbVOFWFnWoJrCRwP0R1QWHg@mail.gmail.com' \
    --to=luto@amacapital.net \
    --cc=akpm@linux-foundation.org \
    --cc=keescook@chromium.org \
    --cc=kernel-hardening@lists.openwall.com \
    --cc=linux-api@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tixxdz@gmail.com \
    --cc=wluikil@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.