Sponsored Content
Full Discussion: Locking in user to $HOME
Top Forums UNIX for Dummies Questions & Answers Locking in user to $HOME Post 17875 by thomas.jones on Wednesday 20th of March 2002 08:50:13 PM
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!!
 

10 More Discussions You Might Find Interesting

1. 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

2. 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

3. 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

4. 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

5. 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

6. 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

7. 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

8. 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

9. 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

10. 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
chroot(1M)																chroot(1M)

NAME
chroot - change root directory for a command SYNOPSIS
newroot command DESCRIPTION
The command executes command relative to the newroot. The meaning of any initial slashes in path names is changed for command and any of its children to newroot. Furthermore, the initial working directory is newroot. Note that command suffixes that affect input or output for the command use the original root, not the new root. For example, the command: locates file relative to the original root, not the new one. The command variable includes both the command name and any arguments. The new root path name is always relative to the current root. Even if a is currently in effect, the newroot argument is relative to the current root of the running process. This command is restricted to users with appropriate privileges. EXTERNAL INFLUENCES
International Code Set Support Single- and multibyte character code sets are supported. WARNINGS
command cannot be in a shell script. Exercise extreme caution when referring to special files in the new root file system. does not search the environment variable for the location of command, so the absolute path name of command must be given. When using to establish a new environment, all absolute path name references to the file system are lost, rendering shared libraries inac- cessible. If continued access to shared libraries is needed for correct operation, the shared libraries and the dynamic loader be copied into the new root environment. SEE ALSO
chdir(2), chroot(2). STANDARDS CONFORMANCE
chroot(1M)
All times are GMT -4. The time now is 07:21 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy