How does Samba Solve this problem?

Jeremy Allison jra at
Mon Jul 22 12:14:21 GMT 2002

On Mon, Jul 22, 2002 at 02:48:48PM +0800, zhangyfh at wrote:
> As we know, in linux, there's no the concept of DENY MODE.
> In M$ windows, when open a file, you use the API
> CreateFile (LPCTSTR lpFileName,
>      DWORD dwDesiredAccess,
>      DWORD dwShareMode,
>      LPSECURITY_ATTRIBUTES lpSecurityAttributes,
>      DWORD dwCreationDistribution,
>      DWORD dwFlagsAndAttributes,
>      HANDLE hTemplateFile)
> the parameter dwShareMode define the deny mode, fo example, if open a file
> with DENY_WRITE, aother applications can't write this file.
> When M$ WORD open a file, then other applications can't write the same
> file.
> But in Linux , when open a file you use open(char *fname, int mode),
> there's no DENY MODE.
> So my question is that, What does Samba do to propose an open request with
> DENY MODE from a window client.

Samba takes care of this internally in the share mode database, it's
not visible to the Linux kernel.


More information about the samba-technical mailing list