Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm trying to configure ProFTPD to match the following situation:

  1. Multiple domains on a single IP address.
  2. Each domain should have it's own anonymous FTP directory.
  3. Everything runs on Ubuntu 12.04LTS VPS server.

For instance, there should be an ftp://example.com and ftp://otherdomain.com, both with their own directories, both allowing only anonymous downloading.

I understand I need to create an IP alias (done using ifconfig eth0:0 192.168.1.100 (and similar for 192.168.1.101)) and set up a virtual host in proftpd.conf or virtuals.conf (tried both). This is what I currently have

<VirtualHost example.com>
    ServerName             "Example.com download"
    DefaultRoot     /var/www/example.com/ftp
    MaxClients      10

    <Anonymous /var/www/example.com/ftp>
        User        ftp
        Group       ftp
        UserAlias   anonymous ftp

        RequireValidShell   no

        DisplayLogin    welcome.msg
        DisplayChdir    .message

        <Limit LOGIN>
            AllowAll
        </Limit>
    </Anonymous>
</VirtualHost>

Whenever I try to access the server with this configuration, I get shown a request for a password. No matter what password I try, I can't get any further.

I've seen sources claim that this is impossible to do with ProFTPD and I've seen sources which give instructions on how to make it work (which I haven't been able to get running). A lot of webhosts have this type of configuration on their cheaper accounts, so it should be possible, although perhaps not with ProFTPd.

Can anybody help configure this type of setup?

share|improve this question
add comment

1 Answer

Don't know if you still have this issue (9+ months on) but this configuration is working for me:

<VirtualHost example.edu>
        RequireValidShell                        off
        ServerName                      "Anonymous FTP Server"
        Port                            4001
        Umask                           027

        <Limit LOGIN>
                DenyAll
        </Limit>

        <Anonymous /home/ftp/>
                User                    ftp
                Group                   nogroup
                UserAlias               anonymous ftp

                <Limit LOGIN>
                        AllowAll
                </Limit>

                <Limit WRITE>
                        DenyAll
                </Limit>

                <Directory incoming>
                        <Limit WRITE>
                                AllowAll
                        </Limit>
                </Directory>
        </Anonymous>
        TransferLog             /var/log/proftpd/xferlogs/anon.log
        # pre-def for firewall.
        PassivePorts            49152 50000

</VirtualHost>
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.