LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 01-30-2017, 09:13 AM   #1
cz.steve
LQ Newbie
 
Registered: Jul 2016
Posts: 14

Rep: Reputation: Disabled
Samba User permissions


Hi,

I m trying to setup custom User permissions for a certain user on my samba server. What i try to achieve is to login with mentioned user, lets say its name is user1, and only access two folders folder1, and folder2(with rwx permissions). The share contains plenty of other folders,which he should NOT see them.
All my samba users are part of a group, lets say its called staff.

My global config is this :

[global]
log file = /var/log/samba/log.%m
load printers = no
socket options = TCP_NODELAY
full_auditrefix = %u|%T|%m|%S
full_audit:facility = local5
interfaces = 192.168.0.20/255.255.255.0
passdb backend = tdbsam
allow hosts = 127. 192.168.0. 192.168.3.
unix extensions = no
cups options = raw
vfs objects = full_audit
full_audit:success = connect disconnect mkdir rmdir write sendfile rename unlink chmod fchmod chown fchown
full_auditriority = notice
workgroup = MYSERVER
full_audit:failure = connect
use sendfile = yes
security = user
max log size = 50

The shared directory config :

[share]
writeable = yes
path = /home/share
vfs object = full_audit
comment = Linux
valid users = user1,user2,user3
create mode = 0660
directory mode = 0770

With this configuration user1 can login and see all the files and folders. (which is not my purpose)

If i erase user1 from the staff group, and set the mentioned folder1, folder2 with the permissions of 777, the user wont have permission to access the server. I just tested it.

So my question is how can i provide for the user accessibility to the share, but restriction to those folders only?

Last edited by cz.steve; 01-30-2017 at 10:17 AM.
 
Old 01-30-2017, 09:27 AM   #2
cz.steve
LQ Newbie
 
Registered: Jul 2016
Posts: 14

Original Poster
Rep: Reputation: Disabled
the mentioned shares permissions are:

drwxrwxr-- 28 root staff 4.0K Jan 30 16:22 share

Even with the read only for other permission, user1 should be able to login, and read the content of share, but he can t.

Last edited by cz.steve; 01-30-2017 at 09:29 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Samba User Permissions MichaelDigital Linux - Newbie 2 06-09-2013 07:01 PM
User permissions - FTP - Samba stascrash Linux - General 3 05-16-2010 06:24 AM
permissions on samba change on specific user actions javeree Linux - Server 1 03-01-2007 03:43 AM
how to setup folder permissions for guest user with samba? wza Linux - Networking 0 07-08-2004 09:26 AM
User permissions for Supermount and Samba Cyrus XIII Linux - Newbie 0 04-17-2004 09:21 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 03:58 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration