Re: [PATCH] vfs: Pass setxattr(2) flags properly

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Apr 20, 2011 at 04:59:06PM -0700, Linus Torvalds wrote:
> Hmm. This patch looks very sane, but it's been that way - ignoring the
> 'flags' value - since 2009. Does anybody actually _use_ the flags
> field?
> 
> Judging by commit 431547b3c453 (that introduced the thing), it looks
> like a plain mistake, and the previous "flags" was replaced by a "0"
> in the call when it added the "hander->flags" argument at the end. But
> the fact that it's been two years, and nobody noticed, makes me go
> "hmm.."

It's not really used very much.  The only use of XATTR_CREATE is to
prevent creating the attrs used for ACLs from the normal xattrs
interface instead of going through the ACL code, and XATTR_REPLACE
is only used to return -ENOATTR when it's set but the attribute
actually is empty.

The first one could probably be used (by root) to create invalid
attrs that confuse the ACL code, and the second may confuse application
using it, although I doubt there are many.

--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux