[SOLVED] Issues with PureFTPD with TLS/SSL on Cpanel (passive open ports)

por | 5 diciembre, 2021
227 Entering Passive Mode (201,161,94,172,253,31)
Error GnuTLS -110 en gnutls_record_recv: The TLS connection was non-properly terminated.

So, you are reading this if you:

a. Are running Cpanel Server (WHM)
b. Using external Firewall
c. Using PureFTPD
d. Passive Mode Enabled
e. Want to get TLS/SSL Working (either forced or optional)

  1. Open your firewall and Add a port range, for example, Protocol: TCP Port Rage: 49200-49600

2. Open WHM and define TLS
In cpanel go to Service Configuration > FTP Server Configuration and change TLS Encryption support to either  “Optional” or “Required”

3. Define passive ports inside of  PureFTPD Configuration
Open SSH and run the following command “nano /etc/pure-ftpd.conf”.

Scroll down to the section called PassivePortRange and add your new ports.

# Port range for passive connections - keep it as broad as possible.

#PassivePortRange 49152 65534
PassivePortRange 49200 49600

After adding your port range, save the file and restart the ftp service using “/usr/local/cpanel/scripts/restartsrv pureftpd”