GnuTLS 错误 -15:使用 SSL 设置 vsftpd 时收到了意外的 TLS 数据包

GnuTLS 错误 -15:使用 SSL 设置 vsftpd 时收到了意外的 TLS 数据包

我在 EC2 上安装了 Ubuntu 14.04,安装了 vsftpd 3.0.2

我已经设置了 SSL 证书,并且我的 vsftpd.conf 是:

listen=YES
anonymous_enable=NO
local_enable=YES
write_enable=YES
dirmessage_enable=YES
use_localtime=YES
connect_from_port_20=YES
xferlog_std_format=YES
chroot_local_user=YES
secure_chroot_dir=/var/run/vsftpd/empty
pam_service_name=vsftpd
rsa_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem
rsa_private_key_file=/etc/ssl/private/ssl-cert-snakeoil.key
ssl_tlsv1=YES
ssl_sslv2=NO
ssl_sslv3=NO
ssl_enable=YES
allow_anon_ssl=NO
force_local_data_ssl=NO
force_local_logins_ssl=NO
require_ssl_reuse=NO
debug_ssl=YES
validate_cert=NO
ssl_ciphers=HIGH
pasv_address=[***** public IP ******]
pasv_enable=YES
pasv_min_port=1024
pasv_max_port=1048

当使用‘通过 TLS 显式 FTP 的 FTP’从 FileZilla 连接时,我得到以下信息:

Status: Resolving address of tcff-ftp.zuriar.net
Status: Connecting to [********]:21...
Status: Connection established, waiting for welcome message...
Response:   220 (vsFTPd 3.0.2)
Command:    AUTH TLS
Response:   234 Proceed with negotiation.
Status: Initializing TLS...
Status: Verifying certificate...
Command:    USER [******]
Status: TLS/SSL connection established.
Response:   331 Please specify the password.
Command:    PASS ************
Response:   230 Login successful.
Command:    OPTS UTF8 ON
Response:   200 Always in UTF8 mode.
Command:    PBSZ 0
Response:   200 PBSZ set to 0.
Command:    PROT P
Response:   200 PROT now Private.
Status: Connected
Status: Retrieving directory listing...
Command:    PWD
Response:   257 "/"
Command:    TYPE I
Response:   200 Switching to Binary mode.
Command:    PASV
Error:  GnuTLS error -15: An unexpected TLS packet was received.
Error:  Disconnected from server: ECONNABORTED - Connection aborted
Error:  Failed to retrieve directory listing

这是什么错误信息?我该如何修复它?据我所知,这与切换到被动模式有关...谢谢。

相关内容