From: Stanislav Kinsburskiy <skinsbursky@virtuozzo.com>
To: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: <peterz@infradead.org>, <mingo@redhat.com>, <mhocko@suse.com>,
<keescook@chromium.org>, <linux-kernel@vger.kernel.org>,
<mguzik@redhat.com>, <bsegall@google.com>,
<john.stultz@linaro.org>, <oleg@redhat.com>,
<gorcunov@openvz.org>, <matthltc@us.ibm.com>,
<akpm@linux-foundation.org>, <luto@amacapital.net>,
<vbabka@suse.cz>, <xemul@virtuozzo.com>
Subject: Re: [PATCH] prctl: remove one-shot limitation for changing exe link
Date: Tue, 26 Jul 2016 12:21:31 +0200 [thread overview]
Message-ID: <449cb90b-faa9-aedd-a33c-d360a44ff199@virtuozzo.com> (raw)
In-Reply-To: <87y44pbmtc.fsf@x220.int.ebiederm.org>
25.07.2016 20:21, Eric W. Biederman пишет:
> Stanislav Kinsburskiy <skinsbursky@virtuozzo.com> writes:
>
>> Gentlemen,
>>
>> Looks like there are no objections to this patch.
> There has been objection.
>
> The only justification for the change that has been put forward is
> someone doing a restore lazily. I don't see a reason why you can't call
> prctl_set_mm_exe_file until you have the file in place instead of a
> place holder that sounds like a trivial solution to any restore issues.
If I understand your proposal correctly, you mean, that the call to
prctl_set_mm_exe_file can be posponed till the actual file is in place.
It can be done this way you propose (although it's ugly).
But you objection looks like you want to preserve some behavior you
believe is reliable.
But it's not.
> The truth is an unlimited settable exe link is essentially meaningless,
> as you can't depend on it for anything. One shot seems the best
> compromise I have seen put forward between the definite
> checkpoint/restart requirement to set the this value and the general
> need to have something that makes sense and people can depend on for
> system management.
Depending on exe link for system management is useful, but can't be
reliable and
can't prevent malicious software to compromise the system.
If we wouldn't have the ability to change exe link, than the only thing
we could be sure,
that process at least started with the binary we believe is reliable.
But since we can change it, the only thing we can rely now is the file
is executable
and process have permissions to execute it.
And this guarantee in preserved across any amount of exe link replacement.
> Also there is a big fat bug in prctl_set_mm_exe_file. It doesn't
> validate that the new file is a actually mmaped executable. We would
> definitely need that to be fixed before even considering removing the
> limit.
Why do we need it? To guarantee, that process has read permission to the
file?
> Right now all I see is people involved in the implementation details of
> their own little feature
>
> So for the patch I am responding to:
> Nacked-by: "Eric W. Biederman" <ebiederm@xmission.com>
>
> Plus the merge window is open so no one is taking any patches right now.
> It is the time to take what has already been staged and get that code
> merged.
>
> Eric
next prev parent reply other threads:[~2016-07-26 10:36 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-12 15:30 Stanislav Kinsburskiy
2016-07-12 16:42 ` Oleg Nesterov
2016-07-12 16:52 ` Stanislav Kinsburskiy
2016-07-12 17:01 ` Oleg Nesterov
2016-07-12 16:48 ` Cyrill Gorcunov
2016-07-12 16:52 ` Eric W. Biederman
2016-07-12 17:29 ` Cyrill Gorcunov
2016-07-12 21:42 ` Cyrill Gorcunov
2016-07-13 10:47 ` Stanislav Kinsburskiy
2016-07-18 20:11 ` One Thousand Gnomes
2016-07-20 11:30 ` Stanislav Kinsburskiy
[not found] ` <8a863273-c571-63d6-c0c3-637dff5645a3@virtuozzo.com>
2016-07-25 18:21 ` Eric W. Biederman
2016-07-25 19:22 ` Cyrill Gorcunov
2016-07-25 19:56 ` Eric W. Biederman
2016-07-26 8:34 ` Cyrill Gorcunov
2016-07-30 17:31 ` Eric W. Biederman
2016-07-30 20:28 ` Mateusz Guzik
2016-07-31 18:45 ` Eric W. Biederman
2016-08-22 15:40 ` Richard Guy Briggs
2016-07-31 22:43 ` Cyrill Gorcunov
2016-07-31 22:49 ` Andy Lutomirski
2016-08-01 9:04 ` Cyrill Gorcunov
2016-08-10 10:48 ` Stanislav Kinsburskiy
2016-07-26 10:21 ` Stanislav Kinsburskiy [this message]
2016-07-12 15:42 Stanislav Kinsburskiy
[not found] <1d254efe-5410-40c4-af4b-9e898682d0b3@email.android.com>
2016-07-13 10:15 ` Oleg Nesterov
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=449cb90b-faa9-aedd-a33c-d360a44ff199@virtuozzo.com \
--to=skinsbursky@virtuozzo.com \
--cc=akpm@linux-foundation.org \
--cc=bsegall@google.com \
--cc=ebiederm@xmission.com \
--cc=gorcunov@openvz.org \
--cc=john.stultz@linaro.org \
--cc=keescook@chromium.org \
--cc=linux-kernel@vger.kernel.org \
--cc=luto@amacapital.net \
--cc=matthltc@us.ibm.com \
--cc=mguzik@redhat.com \
--cc=mhocko@suse.com \
--cc=mingo@redhat.com \
--cc=oleg@redhat.com \
--cc=peterz@infradead.org \
--cc=vbabka@suse.cz \
--cc=xemul@virtuozzo.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®