I'm trying to establish a connection with a FTP server by using FTPS. The server is configured to request a TLS communication for the authentification only, that means the datas have to be send in clear. So, to do that, I tried the ClearControlChannel method. It seems to work but when I try to send a file to the server, my application freezes. So, I then try to use the SendCommand method : PBSZ 0, PROT C, CCC. When I try to send a file, I have now this return :
ChilkatLog: PutFile: DllDate: Jan 21 2015 ChilkatVersion: 188.8.131.52 UnlockPrefix: SEPAMEFTP Username: METEO-ETUDES:EMI Architecture: Little Endian; 32-bit Language: ActiveX VerboseLogging: 0 LocalFilename: C:/FichiersXML/GRmaintenance.xml RemoteFilename: /home/ftpuser/upload/GRmaintenance.xml ProgressMonitoring: enabled: yes heartbeatMs: 0 sendBufferSize: 65536 --ProgressMonitoring IdleTimeoutMs: 60000 ReceiveTimeoutMs: 60000 ConnectTimeoutSeconds: 60 uploadFromLocalFile: localFileSize: 13560 uploadFromDataSource: initialGreeting: 220-Ubuntu 14.04.1 LTS n l 220 FTP Server ready. restartNext: 0 modeZ: 0 binaryMode: 1 pbsz_protp: sendCommand: prepControlChannel: processAlert: TlsAlert: level: warning descrip: close notify --TlsAlert --processAlert --prepControlChannel sendingCommand: PBSZ 0 --sendCommand readCommandResponse: Already received close-notify. Failed to receive more bytes. Failed to read FTP control channel reply. --readCommandResponse --pbsz_protp --uploadFromDataSource Failed. --uploadFromLocalFile TotalTime: Elapsed time: 0 millisec Failed. --PutFile --ChilkatLog
What can be wrong ?
The ClearControlChannel method is to revert the control/command channel back to an unencrypted connection. That's not what you want.
What you instead want is for the control/command connection to be encrypted (which it is), but for the data connections to be unencrypted. This new build includes a new DataProtection property:
See the online documentation for it, which I've just now updated.
DataProtection: Controls the data protection level for the data connections. Possible values are "control", "clear", or "private".
Let me know if you have trouble..
Thanks, it seems clear. I'm going to try rigth now.