[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Samba persmissions



On Mon, 2002-01-28 at 09:08, Christopher Rector wrote:
> I'm having permissions problems on a Samba configuration.
> 
> I'm setting up a test box with Redhat 7.1 and Samba 2.2.2 and want to
> create a common share folder I want everyone to have both read and write
> access to anything in the folder.
> 
> What I'm getting is a folder that allows anyone to read a file, but only
> the owner/creator can modify the file. On my test set up I have set the
> linux permissions on the folder to 777 (testing only), the permissions
> on the smb.conf/NT side are create mask = 0644
> directory mask = 0755 / on the NT side it's set for change permissions.
> 
> Can anyone help me get this set correctly? I'm a relative newbie on
> Linux and am currently trying to get away from the dependence on
> Micro$oft.

The way I did it was to create a user and group, both called public.  I
made a share (/home/public), set it's permisisons to
public.public/2770.  Then, add everyone who needs access to the public
share to the public group.  In smb.conf, force the file create mode to
0660 and the dir create mode to 2770.  The SGID bit on the directories
*should* be enough, but I usually add a "force group = public" to the
smb.conf just in case - and add "write list = @public" as well.

If you'd prefer to not maintain a list of users, you could set the dir
to 0700, set files to create with 0600 and dirs to create with 0700, and
force both user and group to "public".  Make the share writeable, and
you'd have a dir that anyone could write to and delete from. 
Personally, I like the groups method, as that way you can track the user
who initially created a file by the file's owner.

Lemme know if that was too cryptic.  Sometimes I do that.

--Danny


-
To unsubscribe, send email to majordomo@luci.org with
"unsubscribe luci-discuss" in the body.