From: Andrew Morton <akpm@osdl.org>
To: James Morris <jmorris@redhat.com>
Cc: sds@epoch.ncsc.mil, aviro@redhat.com,
linux-kernel@vger.kernel.org, russell@coker.com.au
Subject: Re: [PATCH][RFC] Remove CLONE_FILES from init kernel thread creation
Date: Mon, 17 Nov 2003 12:49:54 -0800 [thread overview]
Message-ID: <20031117124954.6fa4e366.akpm@osdl.org> (raw)
In-Reply-To: <Xine.LNX.4.44.0311171439590.2731-100000@thoron.boston.redhat.com>
James Morris <jmorris@redhat.com> wrote:
>
> The patch below removes the CLONE_FILES flag from the kernel_thread() call
> which starts init.
>
> This is to prevent other kernel threads from sharing file descriptors
> opened by init (try 'lsof /dev/initctl' on a 2.6 system :-).
>
> The reason this patch is being proposed is so that usermode helper apps
> launched via kernel threads (e.g. modprobe, hotplug) do not then inherit
> any such file descriptors. This is not a problem in itself so far (other
> than being messy), but it is a problem for SELinux, which will otherwise
> need to grant access to /dev/initctl by modprobe and hotplug, a somewhat
> undesirable scenario.
>
> As far as I can tell, there is no reason why init needs to be spawned with
> CLONE_FILES. Please let me know if there are any objections to the
> change, which I would like to propose for 2.6.0+ as a cleanup.
>
No, I can't think of a reason why we'd need CLONE_FILES in there. I'll
toss it in and see what breaks.
I wonder why call_usermodehelper() uses CLONE_FILES...
next prev parent reply other threads:[~2003-11-17 20:49 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-11-17 20:00 James Morris
2003-11-17 20:49 ` Andrew Morton [this message]
2003-11-17 21:18 ` James Morris
2003-11-17 21:25 ` Chris Wright
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=20031117124954.6fa4e366.akpm@osdl.org \
--to=akpm@osdl.org \
--cc=aviro@redhat.com \
--cc=jmorris@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=russell@coker.com.au \
--cc=sds@epoch.ncsc.mil \
/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®