Locking in user to $HOME


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Locking in user to $HOME
# 1  
Old 03-20-2002
Locking in user to $HOME

Is there a very easy and configurable method to lock a user into their home directory?

I've checked on chroot() methodology.....but i'm not to excited about copying around ( or symlinking) libraries..binaries....etc.

Thought about altering the groups via chgrp...to only allow read access to $HOME. But that seems like alot of extra work.

I am hoping some of you more seasoned unix guru's out there, have a couple of tricks you can teach me!Smilie

BTW...the users are general.....will probably login via SSH...and will just drop of a few text files. I am allowing a group of individuals to log into one of my computers to test out the Linux OS. Mostly just pine....a little documentation..etc.

Thanks for your help!!
# 2  
Old 03-21-2002
Probably the easiest way that I am aware of for a lightweight control would be using permissions.
I would assume that chmod'ing everything to a value like 700, so that even if they're in the same group, they can't read other's files by default. There would only be a few directoryies that you'd have to lock down to keep them from checking other people's directories, but they would still have read access to places like /bin, /etc, /usr... unless of course, you went all out and changed permissions, and perhaps added a few extra groups, for directory listing access to those dirs.

You'd also need to change their umask to 077 in their .profile (or whatever is used, based on the shell).

If this might work for you, I could provide a few examples...

And I agree - in most cases, chroot is a very large hassle for a small task.
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Switching from root to normal user takes me to user's home dir

Whenever i switch from root to another user, by doing su - user, it takes me to home directory of user. This is very annoying as i want to be in same dir to run different commands as root sometimes and sometimes as normal user. How to fix this? (1 Reply)
Discussion started by: syncmaster
1 Replies

2. Solaris

How to unmount user home directories ??

I've allocated /exports for all user directories by making separate directories under /exports..... :rolleyes: now i need to unmount /exports . But i'm unable to do that.. How can i troubleshoot this issue. Thanks in advance:D (2 Replies)
Discussion started by: vamshigvk475
2 Replies

3. Shell Programming and Scripting

Home of user that is stored in var

I have a user name that is stored in variable $i and i want to use that user's home dirctor in case command something like this find ~"$i" |while read p do case "$p" in ( ~"$i"/myDir ) echo "$p" ;; (*) esac done but it doesn't work some help please (7 Replies)
Discussion started by: testman84
7 Replies

4. Solaris

how to change /export/home/user dir to /home /user in solaris

Hi all i am using solaris 10, i am creating user with useradd -d/home/user -m -s /bin/sh user user is created with in the following path /export/home/user (auto mount) i need the user to be created like this (/home as default home directory ) useradd -d /home/user -m -s /bin/sh... (2 Replies)
Discussion started by: kalyankalyan
2 Replies

5. Red Hat

User's home directory

Hi, By default user's home directory will be /home/$user. I want to change it to /javauser/$user. How can I do it? Thanks Jeevan. (5 Replies)
Discussion started by: jredx
5 Replies

6. AIX

/home belongs to a user?

While doing a "little" clean up job, i noticed something weird... A ls -altr of my / showed this: drwxr-xr-x 1549 johcham grands 102400 Jan 28 13:13 home How can a user become the owner / modify the group of my /home??? any thoughts? Can i chown this back to bin:bin (i think that... (2 Replies)
Discussion started by: Stephan
2 Replies

7. Shell Programming and Scripting

home vs user

Hello, I am trying to find out all users who still have a home dir but do not exist anymore in /etc/passwd file. Here is what I did but I am getting the opposit of what I want. Any suggestion? for USAGERD in `find /home -type d -exec ls -d {} \;` do USAGER=${USAGERD##/*/}... (4 Replies)
Discussion started by: qfwfq
4 Replies

8. Shell Programming and Scripting

how to find out the home directory of a user??

Hi all, I would like to know how to find out the home directory of a particular user.. eg, If am the root , then my Home directory will be / if say am just a user logging into the terminal then my home dir would change, so accordingly i would like to know how to find it out... I know that... (7 Replies)
Discussion started by: wrapster
7 Replies

9. Solaris

Auto Locking user accounts

Hi, I am trying to setup account locking in Solaris 9. I have made the changes in /etc/default/login where RETRIES=5 and SYSLOG_FAILED_LOGINS=5 and in /etc/user_attr I am having: test_user::::lock_after_retries=yes Still I am not able to lock test_user after successive unsuccessful... (1 Reply)
Discussion started by: run_time_error
1 Replies

10. UNIX for Advanced & Expert Users

How can I forbid a user to go up his home directory

Hi everybody, How can I forbid a user to go up his home directory ? Thanks MarcoW (2 Replies)
Discussion started by: MarcoW
2 Replies
Login or Register to Ask a Question