LinuxQuestions.org
Review your favorite Linux distribution.
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 10-04-2006, 05:22 PM   #1
arapidsfan
LQ Newbie
 
Registered: Oct 2005
Posts: 12

Rep: Reputation: 0
Samba shares all home directories


At my school I have a problem, We use a samba domain login for everyone.

the home directories are shared, where kids can save files,

You can acess it by //school/username, but you can change that by goiing to //school/username2 and view those files. Which is a major problem how should I fix it.

It is running Red Hat enterprise 2.
 
Old 10-04-2006, 05:56 PM   #2
Brian1
Guru
 
Registered: Jan 2003
Location: Seymour, Indiana
Distribution: Distribution: RHEL 5 with Pieces of this and that. Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700

Rep: Reputation: 61
Add the option ' browseable=no ' to the share I think may work.

Brian
 
Old 10-04-2006, 07:13 PM   #3
arapidsfan
LQ Newbie
 
Registered: Oct 2005
Posts: 12

Original Poster
Rep: Reputation: 0
No, that is already set. I believe (correct me if I am wrong) makes it so when you browse to //school the directories are not viewable, but you can still type it in.
 
Old 10-04-2006, 07:33 PM   #4
Brian1
Guru
 
Registered: Jan 2003
Location: Seymour, Indiana
Distribution: Distribution: RHEL 5 with Pieces of this and that. Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700

Rep: Reputation: 61
Ok, never tried it but I think you need to set the mask for an option under your share.
Example: change to what you need.
create mask = 0640
directory mask = 0750

Brian
 
Old 10-04-2006, 07:42 PM   #5
arapidsfan
LQ Newbie
 
Registered: Oct 2005
Posts: 12

Original Poster
Rep: Reputation: 0
Ok, what does that do? and how should I change that, It is the premissions but, I dont see how that changes anything.
 
Old 10-05-2006, 08:26 AM   #6
arapidsfan
LQ Newbie
 
Registered: Oct 2005
Posts: 12

Original Poster
Rep: Reputation: 0
[global]
smb passwd file = /etc/samba/smbpasswd
guest account = gueststudent
preserve case = yes
socket options = TCP_NODELAY SO_SNDBUF=8192 SO_RCVBUF=8192
logon drive = H:
deadtime = 5
guest ok = yes
domain master = yes
encrypt passwords = yes
public = yes
wins support = yes
dns proxy = yes
netbios name = academy
server string = Samba Server %v %h
logon script = %g.bat
local master = yes
workgroup = lab
logon path = \\%N\Profiles\%u
os level = 64
debug level = 0
security = user
add machine script = /usr/sbin/useradd -d /dev/null -g machines -s /bin/false -M %u
short preserve case = yes
max log size = 100
domain logons = yes

[homes]
browseable = no
read list = @administrator
writeable = yes
write list = @administrator
only user = yes
comment = My Home Folder
create mode = 0640
directory mode = 0750

[Animals]
comment = US Animals
path = /home/curriculum/AnimalsCD
browseable = yes
public = yes
read only = no
create mask = 0755
directory mask = 0755

I have tried changing the modes in home to no avai tried 0600 and 0700 and 0640 0750.
 
Old 10-05-2006, 05:42 PM   #7
lior.okman
LQ Newbie
 
Registered: Sep 2006
Distribution: Debian GNU/Linux
Posts: 9

Rep: Reputation: 0
Just change the permissions on the home directories so that they don't allow anybody other than the user to access their contents.

Code:
cd /home
chmod 700 *
The "directory mode" and "create mode" options aren't relevant - they are used when a user creates a new file or directory from a remote client.

However, the actual access to the directory is done using the permissions of the user that was authenticated against samba - that means that if the directory belongs to username1 and username2 wouldn't have been able to "ls" the directory on the command-line, then \\server\username1 won't work for username2 - the server will respond with "permission denied".
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
win xp home edition and samba home shares scheidel21 Linux - Software 8 10-09-2008 12:47 AM
How To Limit Samba Shares In /Home Harpo Linux - Software 1 03-29-2006 06:50 AM
10.0 beta 4 tiny niggle -- SAMBA shares don't display all the directories 1kyle Suse/Novell 1 09-10-2005 01:12 PM
Samba does not allow writing to public shares / browsing home directories disallowed Xolo Linux - Software 6 02-14-2005 04:22 PM
Why can't I see the files in the directories on my Samba-Shares? Asuka Tabi Linux - Software 1 06-21-2001 01:10 PM


All times are GMT -5. The time now is 06:37 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration