Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756673Ab0ANJXe (ORCPT ); Thu, 14 Jan 2010 04:23:34 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1756554Ab0ANJXc (ORCPT ); Thu, 14 Jan 2010 04:23:32 -0500 Received: from atrey.karlin.mff.cuni.cz ([195.113.26.193]:54888 "EHLO atrey.karlin.mff.cuni.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756611Ab0ANJX3 (ORCPT ); Thu, 14 Jan 2010 04:23:29 -0500 Date: Thu, 14 Jan 2010 10:23:28 +0100 From: Pavel Machek To: "Serge E. Hallyn" Cc: Michael Stone , linux-kernel@vger.kernel.org, netdev@vger.kernel.org, linux-security-module@vger.kernel.org, Andi Kleen , David Lang , Oliver Hartkopp , Alan Cox , Herbert Xu , Valdis Kletnieks , Bryan Donlan , Evgeniy Polyakov , "C. Scott Ananian" , James Morris , "Eric W. Biederman" , Bernie Innocenti , Mark Seaborn , Randy Dunlap , Am?rico Wang , Tetsuo Handa , Samir Bellabes , Casey Schaufler , Al Viro , Kyle Moffett Subject: Re: [PATCH 2/3] Security: Implement disablenetwork semantics. (v4) Message-ID: <20100114092328.GB11500@atrey.karlin.mff.cuni.cz> References: <20100111174922.GA17285@us.ibm.com> <20100112061058.GA5231@heat> <20100112155246.GA9255@us.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20100112155246.GA9255@us.ibm.com> User-Agent: Mutt/1.5.13 (2006-08-11) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2070 Lines: 49 > Quoting Michael Stone (michael@laptop.org): > > Serge Hallyn wrote: > > >Michael, I'm sorry, I should go back and search the thread for the > > >answer, but don't have time right now - do you really need > > >disablenetwork to be available to unprivileged users? > > > > Rainbow can only drop the networking privileges when we know at app launch time > > (e.g. based on a manifest or from the human operator) that privileges can be > > dropped. Unfortunately, most of the really interesting uses of disablenetwork > > happen *after* rainbow has dropped privilege and handed control the app. > > Therefore, having an API which can be used by at least some low-privilege > > processes is important to me. > > > > >is it ok to require CAP_SETPCAP (same thing required for dropping privs from > > >bounding set)? > > > > Let me try to restate your idea: > > > > We can make disablenetwork safer by permitting its use only where explicitly > > permitted by some previously privileged ancestor. The securebits facility > > described in > > > > http://lwn.net/Articles/280279/ > > > > may be a good framework in which to implement this control. > > > > Did I understand correctly? If so, then yes, this approach seems like it would > > work for me. > > That is a little more than I was saying this time though I think I > suggested it earlier. > > But really I don't think anyone would care to separate a system into > some processes allowed to do unprivileged disablenetwork and other > processes not allowed to, so a (root-owned mode 644) sysctl seems just > as useful. Global solution like that is always wrong. (And we have better solution available.) Pavel -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/