From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andy Lutomirski Subject: Re: [PATCH v2 2/9] procfs: add proc_allow_access() to check if file's opener may access task Date: Fri, 4 Oct 2013 16:08:06 -0700 Message-ID: References: <20131003201332.GA3500@dztty> <20131004085911.GA2157@dztty> <20131004182353.GA2600@dztty> <20131004191113.GA3916@dztty> <20131004192712.GA4334@dztty> <20131004194142.GA4524@dztty> <87fvsgy7cn.fsf@xmission.com> Reply-To: kernel-hardening@lists.openwall.com Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Cc: Djalal Harouni , Kees Cook , Al Viro , Andrew Morton , Linus Torvalds , Ingo Molnar , "Serge E. Hallyn" , Cyrill Gorcunov , David Rientjes , LKML , Linux FS Devel , "kernel-hardening@lists.openwall.com" , Djalal Harouni To: "Eric W. Biederman" Return-path: List-Post: List-Help: List-Unsubscribe: List-Subscribe: In-Reply-To: List-Id: linux-fsdevel.vger.kernel.org On Fri, Oct 4, 2013 at 3:59 PM, Andy Lutomirski wrote: > > I'd really like a solution where there are no read or write > implementations in the entire kernel that check permissions. Failing > that, just getting it for procfs would be nice. (uid_map, etc will > probably need to be revoked on unshare for this to work.) By "check permissions" I mean using anything but f_cred. uid_map won't need any form of revoke, though -- the stuct file already points at a particular target ns. I wonder why the CAP_SYS_ADMIN check is in map_write instead of open, though. --Andy