LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   ftp up/download permission prob (https://www.linuxquestions.org/questions/linux-networking-3/ftp-up-download-permission-prob-88917/)

Stex 09-03-2003 03:07 PM

ftp up/download permission prob
 
hi,

i got a question on vsftpd. i have a virtual user called "virtual" who got a directory called "ftp"(user=virtual, group=virtual) which is located in the apache serve directory.
If i upload files to the "ftp" directory the files have the following permissions: -rw------- . I think that means only the owner, here virtual can read and write the files.
Ok my intension is, if the user virutal uploads files i.e. html files everybody should be able to read these files.
How can i reach that. Is there a paramater for the vsftpd.conf file which let me do that? Or how can i do that.

Thanks for any help
Greetz from the newbie stex :)

Addition: I want the right -rw-r--r--

dubman 09-03-2003 06:10 PM

I set up exactly what you are trying to do...There are functions in the vsftpd.conf for changing wonership and permissions on upload, but I didnt have any luck getting it to work. So, I wrote a bash script to do a chown and chmod for everything in the html (or whatever) directory. I made it a cron job to run every 5 minutes. This worked for me, but I am sure there is a better way to do it.

hope this helps...
--dubman

Stex 09-04-2003 02:04 AM

hi,

hmm a cronjob? Thats elaborately. And with a cronjob, the minimum time i can execute i think is one minute? Am I right? So if i sit in front of my server and has uploaded a test file (html, php) i must wait at least one minute :( Thats a bad workflow :)
But thanks for the reply. I hope theres another solution.

Do u know a site where are all vsftpd.conf functions shown? I think there must be one function for our
intension.

Thanks 4 help

dubman 09-04-2003 05:08 PM

yeah, like i said i am sure there is a better way, but the file will still be available for web access imeadiatly upon upload.

--dubman

Stex 09-04-2003 05:10 PM

hey i got the solution,

try depending on your config the functions
local_umask=022 or anon_umask=022

I think 4 u that must help. It solved my prob

greetz

chintee 09-17-2003 04:48 PM

Sorry to sidetrack, I need help from Stex.
I set up virtual users and map them to a local user, say virtualuser.
But now I want them to have different home directory.
ie:
user1 (after log in) -> chroot in /var/ftpuser1
user2 (after log in) -> chroot in /var/ftpuser2

Could you possibly show me the related vsftpd.conf configuration, the vsftpd_user_conf configuration and settings that need tweaking.

Thanks.

Sorry, I feel like it is not appropriate to interrupt here. :( Please ignore. I solved 90% of the problem already.:D

markus1982 10-03-2003 01:23 PM

following posts answers everything: http://www.linuxquestions.org/questi...threadid=65393


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