FAT, NTFS, CIFS and DOS attributes

Michael B Allen mba2000 at ioplex.com
Mon Jan 3 23:26:12 GMT 2005


H. Peter Anvin said:
> I noticed that CIFS has a placeholder "user.DosAttrib" in cifs/xattr.c,
> although it doesn't seem to be implemented.
>
> Questions:
>
> a) is xattr the right thing?  It seems to be a fairly complex and
> ill-thought-out mechanism all along, especially the whole namespace
> business (what is a system attribute to one filesystem is a user
> attribute to another, for example.)

Ahh, just go with xattrs Pete :-> I don't see the namespace issue to be a
big deal. The interface does seem a *little* overdesigned. It would have
been adequate to just use the dev:ino pair from stat(2) and dump
namespaces altogether since the real performance critical apps will have
stat'd the living daylights out of the path trying to canonicalize the
case so the last thing you want to do is a path lookup.

> b) if xattr is the right thing, shouldn't this be in the system
> namespace rather than the user namespace?

If we're just thinking about MS-oriented discretionary access control then
I think the owner of the file is basically king and should be the only
normal user to that can read and write it's xattrs. So whatever namespace
that is (not system).

> c) What should the representation be?  Binary byte?  String containing a
> subset of "rhsvda67" (barf)?

Definitely binary.

Mike


More information about the samba-technical mailing list