Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

FTPS implicit TLS/SSL error

Tags:

ftp

ftps

I am using FTP over implicit SSL to upload some files. I encountered the following error message

[Command]  PWD
[Response]  257 "/" is current directory.
[Command]  PWD
[Response]  257 "/" is current directory.
[Command]  TYPE A
[Response]  200 Type set to A
[Command]  PWD
[Response]  257 "/" is current directory.
[Command]  PASV
[Response]  227 Entering Passive Mode (10,0,0,19,195,113)
[Command]  LIST -aL
[Response]  521 PROT P required
[Command]  PWD
[Response]  257 "/" is current directory.
[Command]  PASV
[Response]  227 Entering Passive Mode (10,0,0,19,195,114)
[Command]  LIST -aL
[Response]  521 PROT P required
[Status] Failed::FTP protocol error. 521 PROT P required.

May I know what is this error message "521 PROT P required" saying?

Thanks

like image 202
alexcctan Avatar asked Mar 24 '14 16:03

alexcctan


2 Answers

type the following: set ftp:ssl-protect-data true

like image 113
Edgardo Cervantes Avatar answered Sep 30 '22 13:09

Edgardo Cervantes


Before starting a data transfer (e.g. creating a new data connection outside the control connection to transfer files or listing) you have to specify the protection level using the PROT command. The main protection levels are P for protected (e.g. SSL encryption) or C for clear (no encryption). The server complains, because you don't specify a protection level and so it does not know how you want to get your data.

The PROT command must be implemented and used by all ftps clients.

like image 32
Steffen Ullrich Avatar answered Sep 30 '22 15:09

Steffen Ullrich