Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Is there any way, to restrict access to SSH and FTP account down to only several directories.

For example on our VPS we have some paths like:

@project root/proj1
@project root/proj2
@project root/proj3

And i want that user1 could access all three, user2 only second and user3 only first and second. Moreover is there any way to show to users only directories allowed to access?

I mean, if for example there are such directorys as:

/var/www/project
/var/www/project2
/var/www/project3

And user might go only to project and project2, but not to project3. So he could access /var/www, but not /var.

P.S. We have DirectAdminand Debian Squeeze.

share|improve this question

2 Answers 2

up vote 1 down vote accepted

You can do this by making symlinks to the real locations in each users' home directory, and restricting FTP access to the home directory only.

ProFTPd can do this, among others.

share|improve this answer

Search more by using these keywords,

FTP virtual directories, FTP virtual user

Try this one.

http://howto.gumph.org/content/setup-virtual-users-and-directories-in-vsftpd/

Try to use VSFTP ,it's more secure than FTP.

share|improve this answer
    
..than ProFTPd, I think you meant. FTP is not a program. –  adaptr Feb 22 '12 at 11:35
    
:D Yap. ftp is a protocol. You should decide what to use. From VSFTP server you can create virtual users + directories. –  Thilina Feb 22 '12 at 11:41
    
we have proftpd, i will dig more ;) –  Jevgeni Smirnov Feb 22 '12 at 13:36

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.