Restricting a user to a direcotry

Hi all,

I have a question regarding confining a user to a particular directory( his home ) only ,In this context the users would be using putty/telnet to get in to the system.

System details :

HP UX B.11.11

HP 9000/800

Users login shell : csh

User needs to be denied cd command or may be cd command to be aliased in such a way that no matter what ever he types in

cd xyz

he is in his home directory and does not go to any other directory.
LVL 1
Peddu_bhanuAsked:
Who is Participating?
 
yuzhCommented:
You can try to use "rksh", if it is a FTP only account (not login shell), please have a look at the answer in http:Q_21943197.html
also have a look at the following note:
http://www.hpug.org.uk/index.php?option=com_content&task=view&id=492&Itemid=93 
0
 
Peddu_bhanuAuthor Commented:
chroot i guess would not be an option as it is for ftp users , i tried doing

alias cd='cd $HOME'

in .profile file of the user.However it confined him to $HOME only and doesn't let him go even in the $HOME sub directories.I would like him to go any where in his $HOME and not in any other directory.

Is there any hack/way apart from chroot
0
Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
yuzhCommented:
It should would!
but you shout get rid of "alias cd='cd $HOME'" .
0
 
Peddu_bhanuAuthor Commented:
Well if i get rid of the alias then i would not be able to achieve the criteria.

So is there a way to tweak the cd ( some how aliasing it) in the profile files of the user so that the is confined to his home directory tree and nothing else.
0
 
yuzhCommented:
With chroot jailed ENV, the user should be able to move around inside the home dir and the sub-dirs (user should be the owner of their home dir).
0
 
Peddu_bhanuAuthor Commented:
Well yuzh as i said I know it is possible using chrooted env .What I need is any other method and NOT chroot env
0
 
Peddu_bhanuAuthor Commented:
I m looking for more options
0
 
yuzhCommented:
>>I m looking for more options
Please post your requirements, so that the experts can help you, have a nice weekend!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.