Hi, I use UFW to secure my server. When i want to open up FTP for the world and i have this rule: 21/tcp ALLOW IN Anywhere People are still not able to connect unless i whitelist their IP. When only port 21 is open they can make a connection but not list the FTP contents. Which ports do i need to open for them to be able to do so?
It depends on which ports you have set as passive port range. Which FTP server application do you use?
I think back in the day i used this guide: https://www.howtoforge.com/tutorial/perfect-server-ubuntu-18-04-nginx-bind-dovecot-and-ispconfig-3/ So it must be pure-ftpd
Please see here on how to define the passive port range in pure-ftpd: https://www.faqforge.com/linux/cont...ange-in-pure-ftpd-on-denian-and-ubuntu-linux/ and the port range you set in pure-ftpd must then be opened in ufw as well.
I checked nano /etc/pure-ftpd/pure-ftpd.conf but this part is commented out: # Port range for passive connections - keep it as broad as possible. # PassivePortRange 30000 50000
The file /etc/pure-ftpd/pure-ftpd.conf is not used on Ubuntu for this configuration. See link in my post above on how to set the passive port range.