[Box Backup-dev] Extended attributes on FreeBSD 5/6

Martin Ebourne boxbackup-dev@fluffy.co.uk
Mon, 13 Feb 2006 01:27:46 +0000


On Sun, 2006-02-12 at 10:58 +0000, James O'Gorman wrote:
> I just had a quick poke around FreeBSD to see how Robert Watson's
> implemented ACLs, and it seems to use /usr/include/sys/acl.h instead of
> xattr.h.
> 
> I guess xattr support for FreeBSD isn't going to make it for the 0.10
> release now, but it'd be nice to have it in a future release.

I'm not sure how much detail you know about acl and xattrs, but they are
quite different things.

It just so happens that on Linux acls were designed using xattrs as
their underlying storage mechanism, so by handling xattrs we get acls
for free. I don't believe this is true of all platforms. Currently box
knows nothing about acls.

What sort of functions are in acl.h? Does it look like they're really
xattr functions (listattr etc) in a different file, or is it a different
API? If the former then we can try and fix something up, otherwise it's
a whole new feature. Abstracting out the attributes support to make it
into a generic interface with implementations for each type would make
the code more flexible and easier I think, maybe such a thing could come
out in the wash in such a change.

Cheers,

Martin.