Allow anonymous password-free access with permissions to sub-folders but no permissions to home folder?

Need help with FileZilla Server? Something does not work as expected? In this forum you may find an answer.

Moderator: Project members

Post Reply
Message
Author
ejenkins
500 Command not understood
Posts: 1
Joined: 2020-03-19 13:24

Allow anonymous password-free access with permissions to sub-folders but no permissions to home folder?

#1 Post by ejenkins » 2020-03-19 13:57

Hi, on the computer where I am running my FileZilla FTP server I have a root directory for files that are accessible via FTP, say C:\FTP\. Within this directory there are several sub-folders with different types of files, say:

Code: Select all

C:\FTP\public_files_1\
C:\FTP\public_files_2\
C:\FTP\private_files\
I would like to enable an anonymous user with no password, and allow read-only access to the public files. The idea is to have a webpage that will list download links to files in \public_files_1\ and \public_files_2\ but the files in \private_files\ should not be accessible to unauthorized users. I would like users to be able to click the links in their web browser to download the public files without being prompted for any credentials, hence the anonymous account with no password.

I actually had this set up on a previous server and it worked. The way I had it setup was by adding three shared folders for the anonymous account. The "Home" folder was C:\FTP\ but there were no permissions, and I additionally shared C:\FTP\public_files_1\ and C:\FTP\public_files_2\ with read-only permissions. This allowed me to have download links on my website formatted as:

Code: Select all

ftp://(server address)/public_files_1/file1.zip
And when users clicked on that link, their web browser would start the download.

Now, I've just tried to replicate this same setup on a new server, however when the users click the links the web browser is prompting them to enter a username/password and the FTP server is displaying the following log message:

Code: Select all

550 User does not have permission to access own home directory
While this is true, the user does have permissions to access the file in the sub-folder they are trying to access, and I didn't have issues with this type of setup in the past.

Any advice is appreciated.

User avatar
boco
Contributor
Posts: 25154
Joined: 2006-05-01 03:28
Location: Germany

Re: Allow anonymous password-free access with permissions to sub-folders but no permissions to home folder?

#2 Post by boco » 2020-03-19 23:56

FileZilla Server doesn't support a "blind" or "dropbox" configuration. For a directory, to be accessible, you need to provide at least the List permission. Without List, the directory becomes unavailable.

The Home directory needs at least the List permission. (As far as I know, the new server rewrite will force List on Home.)
The public_files_1 and public_files_2 directories need List and Read, so they are accessible and you can download files from them.
Add the private_files directory for that user and assign no permissions. It will vanish completely.
### BEGIN SIGNATURE BLOCK ###
No support requests per PM! You will NOT get any reply!!!
FTP connection problems? Do yourself a favor and read Network Configuration.
FileZilla connection test: https://filezilla-project.org/conntest.php
### END SIGNATURE BLOCK ###

Post Reply