Solved

FTP Permissioning

Posted on 2000-03-24
3
353 Views
Last Modified: 2008-03-06
I am running an FTP server on RH6.  I have 2 questions.
I created a directory called upload. I have permissioned the Dir so that everyone has 'rwx' access (chmod 777).  However when I ftp into it I still can not upload files to that dir. It tells me upload access is denied.
Assuming I can get that working, then my second question would be:

How would I give just one user write or upload permission to
the upload dir on my ftp server (/home/ftp/upload)? Would have to make him a new group and do a chgrp on the directory??

Thanks
0
Comment
Question by:jkipp_66
3 Comments
 
LVL 4

Accepted Solution

by:
kiffney earned 200 total points
Comment Utility
If you have an /etc/ftpaccess file, you need a line in it that says something like

upload /home/ftp /incoming yes ftp ftp 0666

in which you should replace /home/ftp with the actual ftp 'root' directory, and under /home/ftp you should have an incoming/ directory with permissions 0777.  I think you also need to have an 'ftp' user created.  the ftpaccess and ftpd man pages have more details, but I think this is the part you might be missing.

The way wu-ftpd (which is what I think that version of redhat uses) handles users by default is it chroots the ftp user to his 'home directory', so the 'ftp' user winds up in the /home/ftp directory (which looks like the only directory since he's chrooted), and the user 'joe' winds up in /home/joe, where he has whatever permissions the upload command gives him.  I could be wrong here though since it's been a while since I messed with this.  
0
 
LVL 40

Expert Comment

by:jlevie
Comment Utility
Actually wu-ftp doesn't chroot to the user's dir. Ordinary users (as listed in the passwd file) have normal rights with respect to uploading/downloading. If they can read/write to a dir while directly logged in they can upload/download to those dirs from ftp.

When you set up anonymous ftp, wu-ftp does chroot to the anon ftp dir.

As noted /etc/ftpaccess can be used to limit/grant ftp privs. You can see what can be done by looking at "man ftpaccess"

0
 
LVL 3

Expert Comment

by:jyu_88
Comment Utility
For fine-tuned config, You'd better off with proftpd. It has Apache-like directory directives to control permission. Also, users will access the sites with the same rights as OS user (so, you can tweak UNIX-style file/directory permission to your like), and it is easy to turn the chroot on for all users, one single directive in the main config file: DefaultRoot ~.
www.proftpd.org
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

In this tutorial I will explain how to make squid prevent malwares in five easy steps: Squid is a caching proxy for the Web supporting HTTP, HTTPS, FTP, and more. It reduces bandwidth and improves response times by caching and reusing frequently-…
It’s 2016. Password authentication should be dead — or at least close to dying. But, unfortunately, it has not traversed Quagga stage yet. Using password authentication is like laundering hotel guest linens with a washboard — it’s Passé.
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.:
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

771 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