[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20121216142810.GB4939@ZenIV.linux.org.uk>
Date: Sun, 16 Dec 2012 14:28:10 +0000
From: Al Viro <viro@...IV.linux.org.uk>
To: tux2002@...nt.ru
Cc: linux-kernel@...r.kernel.org
Subject: Re: Re: [PATCH] subsystem: pr??oc filesystem
On Sun, Dec 16, 2012 at 04:02:03PM +0400, tux2002@...nt.ru wrote:
> Not, this permissions saved for all users for later, check please.
... and that's why it's bogus. umask of whoever had done lookup for
/proc/<something> affects everybody else. For as long as the thing stays
in dcache. At which point it's up for grabs (in that sense) again.
Do (umask 777; ls -l /proc) with your kernel and watch the results.
Note that you don't need to be root to cause that - anyone can do it.
Realize that dentries and inodes in /proc/<pid>/* are created on demand
whenever somebody does a lookup. So running ps(1) suddenly makes you
a creator of a bunch of those. Unless somebody else had done ps(1) (or
ls -l /proc, or...) first. Basing any security decisions on _that_ is
insane.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists