From: Benny Amorsen Subject: Re: RFC: disablenetwork facility. (v4) Date: Tue, 29 Dec 2009 21:10:11 +0100 Message-ID: References: <20091229050114.GC14362@heat> <20091229151146.GA32153@us.ibm.com> <3e8340490912290805s103fb789y13acea4a84669b20@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: "Serge E. Hallyn" , "Eric W. Biederman" , 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 , Evgeniy Polyakov , "C. Scott Ananian" , James Morris , Bernie Innocenti , Mark Seaborn , Randy Dunlap , =?utf-8?Q?Am=C3=A9rico?= Wang , Tetsuo Handa , Samir Bellabes , Casey Schaufler , Pavel Machek To: Bryan Donlan Return-path: Received: from gate1.ipvision.dk ([94.127.49.2]:59040 "EHLO gate1.ipvision.dk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752409AbZL2UfO (ORCPT ); Tue, 29 Dec 2009 15:35:14 -0500 In-Reply-To: <3e8340490912290805s103fb789y13acea4a84669b20@mail.gmail.com> (Bryan Donlan's message of "Tue, 29 Dec 2009 11:05:09 -0500") Sender: netdev-owner@vger.kernel.org List-ID: Bryan Donlan writes: > I, for one, think it would be best to handle it exactly like the > nosuid mount option - that is, pretend the file doesn't have any > setuid bits set. There's no reason to deny execution; if the process > would otherwise be able to execute it, it can also copy the file to > make a non-suid version and execute that instead. Execute != read. The executable file may contain secrets which must not be available to the user running the setuid program. If you fail the setuid, the user will be able to ptrace() and then the secret is revealed. It's amazing how many security holes appear from what seems like a very simple request. /Benny