Originally Posted by tonytj
I use Samba to create files from Windows but I get wrong protection
When I create a file in a fileshare from Windows I get this protection 744. I want to have 700 because the file should not be allowed to read by any group or other.
I use default smb.conf except this
I think I solved it by using this configuration
comment = only valid for the boss
path = /mnt
public = no
guest ok = no
writeable = yes
browseable = yes
valid users = tony
host allow = 192.168.1.110
create mask = 0700
directory mask = 0700
That will do what you intend. I'm guessing that you're inquiring if there are other techniques to do this, or if there are better choices. My opinion is that while there may be other techniques, this one is fine and I would choose to use it for my configuration if I were configuring for a similar problem.
What I'm not so keen on is the "host allow" line, because host addresses can be different if they are DHCP assigned.