xfs
[Top] [All Lists]

Re: [PATCH 3/3] use inode_change_ok for setattr permission checking

To: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Subject: Re: [PATCH 3/3] use inode_change_ok for setattr permission checking
From: Dave Chinner <david@xxxxxxxxxxxxx>
Date: Tue, 28 Oct 2008 14:00:41 +1100
Cc: xfs@xxxxxxxxxxx
In-reply-to: <20081027133640.GD761@xxxxxxxxxxxxx>
Mail-followup-to: Christoph Hellwig <hch@xxxxxxxxxxxxx>, xfs@xxxxxxxxxxx
References: <20081027133640.GD761@xxxxxxxxxxxxx>
User-agent: Mutt/1.5.18 (2008-05-17)
On Mon, Oct 27, 2008 at 09:36:40AM -0400, Christoph Hellwig wrote:
> Instead of implementing our own checks use inode_change_ok to check for
> nessecary permission in setattr.  There is a slight change in behaviour
  ^^^^^^^^^
necessary

> as inode_change_ok doesn't allow i_mode updates to add the suid or sgid
> without superuser privilegues while the old XFS code just stripped away
> those bits from the file mode.

Better to get an error than silently lose them, I think.

> (First sent on Semptember 29th)
> 
> 
> Signed-off-by: Christoph Hellwig <hch@xxxxxx>

Reviewed-by: Dave Chinner <david@xxxxxxxxxxxxx>

-- 
Dave Chinner
david@xxxxxxxxxxxxx

<Prev in Thread] Current Thread [Next in Thread>