From mboxrd@z Thu Jan 1 00:00:00 1970 From: James Morris Subject: Re: [patch 07/24] fat: dont call notify_change Date: Fri, 9 May 2008 09:45:02 +1000 (EST) Message-ID: References: <20080506091327.259950960@szeredi.hu> <20080506091414.440652004@szeredi.hu> <20080508165724.GD13914@infradead.org> Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: Miklos Szeredi , akpm@linux-foundation.org, viro@ZenIV.linux.org.uk, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, OGAWA Hirofumi , sds@tycho.nsa.gov, casey@schaufler-ca.com To: Christoph Hellwig Return-path: Received: from namei.org ([69.55.235.186]:48189 "EHLO us.intercode.com.au" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753740AbYEHXqH (ORCPT ); Thu, 8 May 2008 19:46:07 -0400 In-Reply-To: <20080508165724.GD13914@infradead.org> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Thu, 8 May 2008, Christoph Hellwig wrote: > On Tue, May 06, 2008 at 11:13:34AM +0200, Miklos Szeredi wrote: > > From: Miklos Szeredi > > > > The FAT_IOCTL_SET_ATTRIBUTES ioctl() calls notify_change() to change > > the file mode before changing the inode attributes. Replace with > > explicit call to fat_setattr(). > > > > This is equivalent, except that security_inode_setattr() is not called > > before fat_setattr(). I think this is not needed, since the mode > > change is just a side effect of the attribute change. > > Actually I think we want the security_inode_setattr. This is an > implicit chmode when switching the ATTR_RO flag on and off and we should > have the full security check for it. Then again I'm not sure the > security modules care about this level of detail because there's > probably even worse ioctl hidden somewhere. > > Ccing the Selinux guys and Casey in case they care. > I don't know of any situation where we'd have policy differentating the ioctl check from setattr for FAT (or any filesystem). - James -- James Morris