Re: [RFC 2/5 v4] procfs: add hidepid= and gid= mount options
From: Vasiliy Kulikov
Date: Mon Jun 20 2011 - 13:06:15 EST
On Mon, Jun 20, 2011 at 20:43 +1000, James Morris wrote:
> > > > hidepid=1 means users may not access any /proc/<pid>/ directories, but their
> > > > own. Sensitive files like cmdline, io, sched*, status, wchan are now
> > > > protected against other users. As permission checking done in
> > > > proc_pid_permission() and files' permissions are left untouched,
> > > > programs expecting specific files' permissions are not confused.
> > >
> > > IMHO such programs are beyond broken and have voided their kernel
> > > warranty.
> > Policykit, Debian's start-stop-daemon, util-linux use /proc/PID's uid.
> > procps use both /proc/PID's uid and gid. Are all of them totally broken?
> If they depend on specific permissions, yes.
Could you please then clarify why does this patch changes
It changes files permissions to allow userspace apps to quickly stat
files, not looking into /proc/PID/status. So, uid and gid are explicit
ABI. Breaking procfs uid/gid attributes would break these apps.
Or am I missing something?
http://www.openwall.com - bringing security into open computing environments
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/