Solved

vsftpd..user can descend..

Posted on 2003-11-05
5
317 Views
Last Modified: 2013-12-16
I have a RedHat Linux 8 box running vsftpd. I'm experiencing an issue where users login and can descend out of their home directories. I've tried various different ways of creating the user.. different groups, uids, etc.. Any ideas?

Regards,
Bill
0
Comment
Question by:nturnet
  • 3
  • 2
5 Comments
 
LVL 40

Accepted Solution

by:
jlevie earned 125 total points
ID: 9689094
By "descend out of their home directories." are you talking about a "joe-user accessing /home/joe-user/sub-dir or a joe-user accessing /home/other-user? you can't keep a user from accessing subdirectories of their FTP "home dir" but you can chroot them into their home dir and prevent them from seeing anything else on the system.
0
 

Author Comment

by:nturnet
ID: 9689237
That is exactly what I want to accomplish.

Mmm.. perhaps I'm doing something wrong here.. The only thing I'm getting is:
chroot: cannot execute /bin/bash: No such file or directory

when I try to excute the chroot command?!?!
0
 
LVL 40

Expert Comment

by:jlevie
ID: 9689463
Are you using "chroot_local_user=YES" in your vsftp config?
0
 

Author Comment

by:nturnet
ID: 9689517
Well, I am now and everything is working perfect.

Now I need to discover a way when adding a user explictly for FTP that it automatically writes that username to the vsftpd.chroot_list..

Thanks again!
0
 
LVL 40

Expert Comment

by:jlevie
ID: 9690011
The only way I know of to do that is to either use a wrapper around useradd/userdel or to set up a cron job that picks users out of /etc/passwd and adds them to the file.
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Join & Write a Comment

Daily system administration tasks often require administrators to connect remote systems. But allowing these remote systems to accept passwords makes these systems vulnerable to the risk of brute-force password guessing attacks. Furthermore there ar…
Using 'screen' for session sharing, The Simple Edition Step 1: user starts session with command: screen Step 2: other user (logged in with same user account) connects with command: screen -x Done. Both users are connected to the same CLI sessio…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now