# Account management



## aadryaan94 (Apr 29, 2013)

I want to create one account, but I want to give access only for one directory (for example: /usr/local/www/apache22), FTP and PuTTY. Can I make such an account?

PS: Sorry for my English


----------



## luckylinux (May 4, 2013)

aadryaan94 said:
			
		

> I want to create one account, but I want to give access only for one directory (for example: /usr/local/www/apache22), FTP and PuTTY. Can I make such an account?
> 
> PS: Sorry for my English



Not sure if I understood your question correctly. Maybe this will help you set up a limited-directory login for SSH login (basically limited to /home/<username> but this could be changed). See http://www.debian-administration.org/articles/590 for instance (based on Debian GNU/Linux, still OpenSSH is also used for FreeBSD).

For FTP users it depends on the FTP server you use. For VSFTP see for instance http://www.cyberciti.biz/tips/vsftp-chroot-users-limit-to-only-their-home-directory.html. For ProFTPd see here: http://www.proftpd.org/docs/directives/linked/config_ref_DefaultRoot.html.

For other informations search on Google terms like "SSH chroot user" or "FTP chroot user".
Hope it helps.


----------



## ShelLuser (May 5, 2013)

aadryaan94 said:
			
		

> I want to create one account, but I want to give access only for one directory (for example: /usr/local/www/apache22), FTP and PuTTY. Can I make such an account?


Apart from the previous response I'd like to warn you that you shouldn't put too much trust in solutions like that. "Chrooting" (limiting) someone to one directory is a decent way to, well, limit your users but it doesn't provide much extra security. Because generally speaking it's often not that difficult to escape such a commandline chroot.

As a rule of thumb you shouldn't provide people shell (SSH) access if you don't trust the safety of your system. Normally there should be no need to keep them inside a chroot because when setup correctly then a normal user would never be able to abuse things.

If you really want to limit people from your real system I'd start by looking into Jails instead.


----------



## aadryaan94 (May 8, 2013)

I need a guide, step by step, how to install. I try to install VSFTP, ProFTPd, but nothing. I don't understand. Can I use a webpage or script for FTP and a .sh file?


----------

