-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ensure that commonly requested xattrs are in SA
Now that we have SA-based xattrs on FreeBSD we should ensure that certain important samba-related xattrs are written to this area rather than in the xattr dir. This avoids having to perform more expensive permissions check, lookup, and read. Since we can't always know what the contents of these xattrs will be beforehand, store empty xattrs and have Samba internally assign special meaning to the ones with no value (e.g. fail read with ENOATTR). This is sufficient to mask the attributes from SMB clients since vfs_streams_xattr will attempt to FGETXATTR prior to appending the xattr to STREAM_INFO response. Three attributes to be stored in this way are: - user.DOSATTRIB (always requested for files) - stream (AFP_AfpInfo) which is used by VFS fruit to generate response to SMB2 FIND_INFO requests when AAPL context negotiated. - stream (AFP_Resource) which is requested by Finder to check for metadata related to icons or other usage of resource forks.
- Loading branch information
Showing
1 changed file
with
122 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters