找回密码
 新建账号

PHPStorm failed to connect to implicit/explicit FTP over TLS

[复制链接]
php 发表于 2017/12/27 16:48 | 显示全部楼层 |阅读模式
Connection to 'wuxiancheng.cn' failed.
Could not list the contents of folder "ftps://wuxiancheng.cn:21/"

Connection to 'wuxiancheng.cn' failed
Could not connect to FTPS server on 'wuxiancheng.cn'

PHPStorm failed to connect to FTPS server? Let's see how to fix this problem.

FTPS = FTP over TLS. There're explicit FTP over TLS and implicit FTP over TLS. Explicit ftp over TLS shares the same port as plain ftp uses while implicit ftp over TLS doesn't.

0. Make sure to set the FTP type as "FTPS" rather than "SFTP" in the "Tools -> Deployment -> Configuration ..." FTP configuration window in PHPStorm, and that you have configured the right port the FTPS server serves. Although the ports of plain FTP and explicit FTP over TLS default to 21, and the port of implicit FTP over TLS defaults to 990, different ports may be configured by the server.

1. Configure the root certificate of the certificate issuer in PHPStorm.

TLS certificates consist of public certificate, private key and root certificate. After your certificate is issued, you can download these three files. The public certificate and the root certificate may be placed in the same file. In this case you should extract it from that file. Suppose the public certificate file is named as certificate.crt, the private key file is named as private.key and the root catificate is named as root.crt.

Goto "File -> Settings -> Server Certificates" in PHPStorm 2017, and click on the "+" button to include the file "root.crt" which is the certificate file  of your certificate issuer.

2. Configure your FTP server.

Take the FileZilla FTP Server as example.

Run "FileZilla Server Interface.exe" and then goto and uncheck the "Edit -> Settings -> FTP over TLS settings -> Require TLS session resumption on data connection when using PROT P" checkbox.

Now you can connect to FTPS server with either explicit FTP over TLS or implicit FTP over TLS in PHPStorm.

手机版|轻松E站

GMT+8, 2024/4/20 12:08

快速回复 返回顶部 返回列表