LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 10-04-2006, 01:04 PM   #1
carlosinfl
Senior Member
 
Registered: May 2004
Location: Orlando, FL
Distribution: Arch
Posts: 2,905

Rep: Reputation: 77
Question Home Directory Question


On our RHEL servers, all users can not browse other home directories except "root" obviously but when I just built this Debian server (Sarge), when I run the "adduser" command to create new users and home directories, each user can browse and view other home directories. How can I restrict this? I want each user to be locked to their home directory. I don't care if they can browse system files but writing or changing system files is another issue of course.

Code:
cwilliams@tunafish:/home$ ls -la
total 20
drwxrwsr-x   5 root      staff     4096 2006-10-04 13:56 .
drwxr-xr-x  21 root      root      4096 2006-10-03 07:13 ..
drwxr-xr-x   3 cwilliams cwilliams 4096 2006-10-04 13:57 cwilliams
drwxr-xr-x   2 dgales    dgales    4096 2006-10-04 13:56 dgales
drwxr-xr-x   2 wackley   wackley   4096 2006-10-04 13:54 wackley
 
Old 10-04-2006, 01:42 PM   #2
cjcox
Member
 
Registered: Jun 2004
Posts: 307

Rep: Reputation: 42
Remove the group and other bits from the home directories. You can also set the umask to 077 if you want for future file/dir creates. Actually, since you are mimicking Red Hat with the unique group names, you can merely remove the "other" bits from the directories and use a umask of 027....

chmod o= /home/*

Even with the permission bits you have, users won't be able to create or remove files inside of each other's home directories (of course, there could be more lenient permission setting on directories underneath their home dirs).
 
  


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
need to link a home directory to an apache directory Melsync Linux - Server 3 09-30-2006 05:08 AM
Apache Root/Home Directory and setting up FTP for home directories? Mankind75 Linux - Newbie 6 07-23-2006 02:37 PM
How to protect a file/directory in your home login directory (RH Linux) jitsenho Linux - Security 9 07-03-2006 11:08 PM
Home directory question BobL Linux - Software 5 01-04-2005 04:28 PM
/home directory structure question Dswissmiss Linux - General 2 09-29-2004 11:54 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 05:16 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