Deny mode behaviour differences?

Mrinal Kalakrishnan lists at
Wed May 4 18:37:49 GMT 2005


I was playing around with file locking using share modes from the
Windows side, and I seem to have stumbled upon some difference in the
locking semantics between Windows and Samba.

If I open a file using CreateFile from the Windows side, Samba
respects the FILE_SHARE_DELETE share mode, i.e. if I'm opening the
file with FILE_SHARE_DELETE, it allows another user to rename/delete
the file, and if I open it without FILE_SHARE_DELETE, it prevents me
from renaming or deleting - which is what I would expect to happen.

However, the same thing doesn't seem to happen with a Windows server.
Whether I open the file with or without the FILE_SHARE_DELETE bit, it
doesn't let anyone else delete or rename the file.

Has anyone seen this before - am I missing something here? I was able
to reproduce this both on NT and XP.

Mrinal Kalakrishnan  || || PGP:B1E86F5B ||
<mail at> || JabberID: <mrinal at> ||

More information about the samba-technical mailing list