samba-users August 2010 archive
Main Archive Page > Month Archives  > samba-users archives
samba-users: Re: [Samba] permissions question

Re: [Samba] permissions question

From: Nicolas Jungers <nicolas_at_nospam>
Date: Tue Aug 31 2010 - 21:02:26 GMT
To: samba@lists.samba.org

On 08/31/2010 10:54 PM, Han Solo wrote:
> I have a samba share that has the following permissions:
>
> create mask = 0775
> force create mode = 0664
> directory create mask = 0775
> force directory mode = 0764
>
> 1.) Does this means DOS/windows files will be created as rwxrwxr-x per
> "create mask" or rw-rw-r-- per "force create mode"?

a mask is a "removal" of bit in the permission, so you get that a bit
wrong :-)

say you have permissions of 777 which in binary is 111-111-111 and a
mask of 022 which is 000-010-010 you have to do the following to get the
final permissions:
     111-111-111
- 000-010-010
= 111-101-101

which is 755

N.

> 2.) Do I need both create mask& force create mode or is one overkill?
> 3.) Is "directory create mask" an unknown option?
> 4.) Does force directory mode mean all dos/windows directories created will
> be drwxrw-r--?
> 5.) I have a basic .txt file I created on my windows desktop by
> right-clicking>new>text document. I copy that file over to the share in
> question& it gets the following permission: -rwxr--r-- where is it getting
> that permission from as I'm expecting it to have 0775 or 0664 permisions&
> neither is coming over.
>
> Please help! Thanks in advance!

-- To unsubscribe from this list go to the following URL and read the instructions: https://lists.samba.org/mailman/options/samba