LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 01-25-2005, 01:25 PM   #1
linuxpyro
Member
 
Registered: Apr 2004
Distribution: Gentoo
Posts: 134

Rep: Reputation: 16
WU-FTPD Config Question


I'm setting up an FTP server on my Fedora Core 1 workstation so I can easily transfer files between home and school. However, because of the fact that FTP is insecure, I would like to set it up so that all users are guest users, and are chrooted to a directory, ftpdrop, in their home directories (this comp gets used by myself and a couple other people). I have gotten the Washington University FTP daemon (wu-ftpd) working, but am not sure how to accomplish this. I have all users set as guest users in the /etc/ftpaccess file, but how can I still have all the users to be able to log in regularly, ie not change their default shells in /etc/passwd so they are only chrooted in the FTP session? I checked the docs but couldn't find anything on this.

Thanks for any ideas...
 
Old 01-25-2005, 01:32 PM   #2
twantrd
Senior Member
 
Registered: Nov 2002
Location: CA
Distribution: redhat 7.3
Posts: 1,440

Rep: Reputation: 52
I haven't touched wu-ftpd for a long time. I've been using vsftpd (which I must say is VERY easy to chroot users). Anyhow, to chroot for wu-ftpd:

1. Edit your /etc/passwd file and change the shell of the user to ftponly. Like /bin/ftponly. If you don't have ftponly, create one. Lots of info on how to do this is on the web. It's very easy.

2. Edit /etc/passwd to look something like this:
user:*:100:100:Test user:/home/user/./:/bin/ftponly

The /./ determines where the chroot() is done to. Therefore, when 'user' ftps in, they should be chrooted to their home dir. Try that out and let me know if it works or not.

-twantrd
 
Old 01-25-2005, 01:52 PM   #3
linuxpyro
Member
 
Registered: Apr 2004
Distribution: Gentoo
Posts: 134

Original Poster
Rep: Reputation: 16
I've gotten that to work for a couple of users already, but it is not what I am trying to do. I only want the chroot to apply to ftp sessions; ie when a user logs in he or she sees the directory $HOME/ftpdrop as the home directory, and is not able to go anywhere else, not even back to the $HOME directory. However, I would still like a the user to be able to log in, either through the consol or through shh, and use the box as you normally would. Thus, I am trying to create a "drop box", where local users can log in remotely to put a file in a directory under their home directory, and then move the file to another location when they come back to log on to the computer locally.
 
Old 01-25-2005, 03:03 PM   #4
twantrd
Senior Member
 
Registered: Nov 2002
Location: CA
Distribution: redhat 7.3
Posts: 1,440

Rep: Reputation: 52
Ahh I see what you mean. Hmmm, I don't know if you can do this.

-twantrd
 
Old 01-25-2005, 05:25 PM   #5
linuxpyro
Member
 
Registered: Apr 2004
Distribution: Gentoo
Posts: 134

Original Poster
Rep: Reputation: 16
It seems like it should be. Oh well, in the mean time I guess I'll just set up one guest with a home directory the other accounts can write to...
 
  


Reply



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
FTPD default permissions (wu-ftpd) bd1308 Linux - Software 1 10-22-2005 06:01 AM
FTPd Question (non anonymous) Mega Man X *BSD 3 01-18-2005 12:11 PM
pure-ftpd - Where is the config file? Moses420ca Linux - Software 1 01-12-2005 03:27 PM
Disabling Kerberos ftpd for wu-ftpd mortisd Linux - Software 0 08-31-2004 05:37 AM
pure-ftpd question mardanian Linux - Software 0 04-01-2004 12:01 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 03:47 AM.

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
Open Source Consulting | Domain Registration