LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-09-2009, 02:34 PM   #1
SuperDude123
Member
 
Registered: Nov 2008
Posts: 158

Rep: Reputation: 30
How to lock user in his home directory on a Debian SSH Server?


I'm presently running a debian box, and I want to add a user, however I don't want the user to have sudo or root privileges, as well as I don;t want the user to be able to leave his home directory (can't go to /, just stay locked at /home/username). How do I do this? Is a VSFTPD what I need?
 
Old 07-09-2009, 04:08 PM   #2
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Willoughby, Ohio
Distribution: linuxdebian
Posts: 7,232
Blog Entries: 5

Rep: Reputation: 190Reputation: 190
http://www.debian.org/doc/manuals/se...sh-env.en.html

http://www.howtoforge.com/chrooted-s...l-debian-lenny
 
Old 07-09-2009, 04:15 PM   #3
karamarisan
Member
 
Registered: Jul 2009
Location: Illinois, US
Distribution: Fedora 11
Posts: 374

Rep: Reputation: 55
http://blogs.techrepublic.com.com/opensource/?p=229

Found this by Googling "ssh chroot user".
 
Old 07-09-2009, 04:17 PM   #4
Wim Sturkenboom
Senior Member
 
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Slackware 10.1/10.2/12, Ubuntu 12.04, Crunchbang Statler
Posts: 3,786

Rep: Reputation: 282Reputation: 282Reputation: 282
It depends on what you want the user to be able to do. If you only want the user to upload/download files, an FTP server is a way (and in my opinion the easiest way).
My approach there is to create a normal user but set the shell to something like /bin/false or /bin/nologin (depending what is available on the system). This will block normal login access. Next setup (the user on) the FTP server. For the latter, you can have a look at the FTP section of Miles Brennan's Linux Home Server HOWTO

If the user should be able to edit his/her files on the system, SSH is the way. It is however more complicated to jail the user to their home directory in my opinion. You can search for ssh jail to find the information.
 
  


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
SSH and User Home Directory htabesh Linux - Security 3 10-29-2008 09:13 AM
debian user home directory afzalmasood Debian 5 07-22-2008 11:31 AM
Locking SSH user to home directory. paroxsitic Linux - Software 2 04-03-2007 06:50 PM
VSFTPD - lock user to home directory ohleary Linux - Software 3 11-20-2003 03:04 PM
SSH lock users to the Home Directory jasonweb Linux - Security 2 04-11-2003 07:20 PM


All times are GMT -5. The time now is 07:27 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration