This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: 1.7.1-1 noacl on samba share has incorrect directory write bit
On Jan 7 00:39, Raman Gupta wrote:
> Well... yes -- at least in this case. As per the documentation
> (http://www.cygwin.com/cygwin-ug-net/using.html#mount-table):
>
> "Cygwin ignores filesystem ACLs and only fakes a subset of
> permission bits based on the DOS readonly attribute"
>
> On the server:
>
> root@smserver foo]# ls -ald bar baz
> dr-xr-sr-x. 2 root agroup 4096 2007-04-21 23:23 bar
> drwxrwsr-x. 2 root agroup 4096 2007-04-21 23:23 baz
>
> Since the default behavior of Samba is to map the DOS read-only flag
> as per the write bits (http://www.samba.org/samba/docs/man/manpages-3/smb.conf.5.html#MAPREADONLY),
> the write bits carry over to the DOS readonly attribute on the
> share. This can be verified via the DOS attrib command on the
> client:
>
> Raman Gupta@client /mnt/shar/foo
> $ attrib bar
> R \\smserver\smshare\foo\bar
>
> Raman Gupta@client /mnt/shar/foo
> $ attrib baz
> \\smserver\smshare\foo\baz
>
> and yet, Cygwin reports owner write bit set in both cases:
>
> Raman Gupta@client /mnt/shar/foo
> $ ls -ald bar baz
> drwxr-xr-x 1 Raman Gupta None 0 2007-04-21 23:23 bar
> drwxr-xr-x 1 Raman Gupta None 0 2007-04-21 23:23 baz
>
> Therefore, it appears that cygwin is following its own documentation
> for files but not for directories.
No, it's a bit more tricky. FAT filesystems, which are the role model
for noacl filesystems don't know something like a R/O directory. The
DOS R/O bit on a directory does NOT mean the directory is R/O. Rather,
it only means that the folder is some sort of special folder. For some
better description, see http://support.microsoft.com/kb/326549.
Therefore the fault is not on Cygwin's side, but on Samba's side to use
the DOS R/O bit for something different than Windows uses it on
directories.
Corinna
--
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Project Co-Leader cygwin AT cygwin DOT com
Red Hat
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple