[RFC] incorrect dosmode on stream associated with dir
awalker at ixsystems.com
Tue Apr 10 10:54:42 UTC 2018
On Mon, Apr 9, 2018 at 8:04 PM, Jeremy Allison <jra at samba.org> wrote:
> On Mon, Apr 09, 2018 at 06:55:25PM -0400, Andrew Walker via
> samba-technical wrote:
> > Hi all,
> > Some of our users have reported that in the following situation:
> > (1) streams_xattr was enabled,
> > (2) store dos attributes = yes,
> > and
> > (3) stream exists on a directory (i.e. Dir:AFP_AfpInfo)
> > when they try to copy "Dir" in File Explorer on a Windows 7 clients,
> > Windows displays "invalid MS-DOS function" and fails to copy the
> > in question. Windows 10, Server 2016 are not affected.
> > Packet captures indicated that in the above situation Samba is setting
> > FILE_ATTRIBUTE_DIRECTORY on Dir:AFP_AfpInfo in the related GetInfo
> > response. Note that from what I have observed, Windows servers do not set
> > this attribute.
> > I applied the attached patch and it fixed the above behavior.
> Andrew, how is the share configured ? I'm trying to reproduce
> this on a share with regular stream (no AFP or vfs_fruit involved)
> and I don't see the same behavior. I'm trying to figure out if
> we need to test this on vfs_fruit specific shares in order to
> reproduce the bug.
Sorry for delay in responding. The issue was observed on FreeBSD, Samba
Version 4.7.6. Also tested against 4.8.0.
### smb.conf ###
idmap config * : range = 3000-7999
idmap config * : backend = tdb
ea support = Yes
store dos attributes = Yes
path = "/usr/home/SAMBA"
read only = No
vfs objects = zfsacl streams_xattr
### lsextattr output ###
root at DC00:/usr/home/SAMBA # lsextattr user Test_Dir/
Test_Dir/ DOSATTRIB DosStream.Cats:$DATA
_both_ a DOSATTRIB and DosStream are required to reproduce bug.
### client ###
windows 7 enterprise, service pack 1, all patches applied
### workflow ###
1) create directory on server.
2) write ADS to directory.
3) copy directory to client desktop (note dir must not exist on client).
More information about the samba-technical