]> git.baikalelectronics.ru Git - kernel.git/commit
proc: Restrict mounting the proc filesystem
authorEric W. Biederman <ebiederm@xmission.com>
Tue, 26 Mar 2013 02:57:10 +0000 (19:57 -0700)
committerEric W. Biederman <ebiederm@xmission.com>
Mon, 26 Aug 2013 18:36:58 +0000 (11:36 -0700)
commit9b7d2a143c1d7efbe4d9a1ebbc31f31707336972
tree29d0afcbf37968e8fccd1dfff76deadf86c7a338
parentb4fb41a1029d1bbe8b4f7510df949ed7c74c48a7
proc: Restrict mounting the proc filesystem

Don't allow mounting the proc filesystem unless the caller has
CAP_SYS_ADMIN rights over the pid namespace.  The principle here is if
you create or have capabilities over it you can mount it, otherwise
you get to live with what other people have mounted.

Andy pointed out that this is needed to prevent users in a user
namespace from remounting proc and specifying different hidepid and gid
options on already existing proc mounts.

Cc: stable@vger.kernel.org
Reported-by: Andy Lutomirski <luto@amacapital.net>
Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
fs/proc/root.c