Jump to content

SMB permissions and umask


bkwq

Recommended Posts

Posted (edited)

Unraid has a umask of 000 which translates to 666 for files and 777 folders.

 

The default Samba config is trying to force 777 on both files and folders.  However the resulting permissions are actually 766 for files and 777 for folders.

 

smb-names.conf
create mask = 0777
directory mask = 0777

 

I believe the default Samba config should be create mask 666 and directory mask 777 to match the system umask.  Even the New Permissions tool within the web interface uses these permissions.

 

This has been bugging me for quite a while now.  I know I can set my own Samba parameters to correct this.  Am I missing something as to why the default config is set?

 

Thank you.

Edited by bkwq
Posted

This is a difficult to figure out as (in my experience) files are created with 666 permissions.  This is the explanation from samba.org on what this parameter is intended to do. 

 

image.thumb.png.1c38ed3a0964a1ae28172059ac9f3e7d.png

 

Normally, UNIX/Linux does not want the 'execute' bit set for files for security reasons.  (This was even true when I took an introductory course in Unix back in the late 1970's when UNIX was still had a bit of the wild west in its developers' hearts!)  

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...