FTP with SSL, Clear Command Channel

HI,

I've got a site that I want to FTP to using the FTP Library. The Admin on the remote server say that I need to do a "Clear command channel" in order to get through his firewall. I don't have a clue as to what he's talking about. Is this even possible to do with smartftp?

Thanks,
kevin

Yes of course.

FTPLib:
Set the CommandProtection property (of the FTPConnection) to ftpDataProtectionClear = 1

SmartFTP:
Just go to the Favorite properties. Then go to the Connection->SSL dialog and set the control connection to Clear.

Regards,
Mat

Thanks,

I guess I still don't fully understand how to write the "ftpDataProtectionClear = 1". Do you have some sample code that I could look at. Here's what I've got so far but I know "objFTP.ftpDataProtectionClear = 1" is not right.


Dim objFTP
Set objFTP = CreateObject("sfFTPLib.FTPConnectionSTA")


objFTP.Host = "xxx.xxx.xxx.xxx"
objFTP.Username = "abcd1243"
objFTP.Password = "zxcv9876"
objFTP.ftpDataProtectionClear = 1
objFTP.Port = 21
path= "/to_xpn"


objFTP.Connect()

You forgot to set the Protocol property to SSLExplicit.

Regards,
Mat

Thanks for all of the help Mat.

I added what you suggested and I am getting an error saying "Object doesn't support this property or method: 'ftpDataProtectionClear' ", It's failing on this line of the script "objFTP.ftpDataProtectionClear = 1" .

Any ideas?

CommandProtection is the name of the property. ftpDataProtectionClear is the name of the constant. So the correct line is:
objFTP.CommandProtection = 1

Same kind of error. I should mention that I'm using the FTPLib and writing the code as VB script.

I am getting an error saying "Object doesn't support this property or method: 'CommandProtection' , It's failing on this line of the script "objFTP.CommandProtection = 1" .

Thanks for taking the time to help me with this problem

Works here as expected. Make sure that you have the latest version of the FTP Library installed:
https://www.smartftp.com/get/SFTPFTPLib.exe

Regards,
Mat

Thanks,

Yes, the most current version does work on my pc. I was able to get my script to run. now I'll just have to sort out why I'm getting a return code of 17 after I execute the connect.

I currently have a license for FTPLib and I am running version 1.5.9.16 on our production server. Do you know if the new version of the dll will allow me to use the same license or do I require an upgrade.

Thanks,
Kevin

Dear Kevin ..

Please contact us at sales@smartftp.com and provide your license key id.

Regards,
Mat

Hi,

I'm setting the following but I am still having problems connecting to the server. The server admin is saying that he's not receiving the the Clear Command Channel.

obj.Host = "xxx.xxx.xxx.xxx"
obj.Username = "abcd1243"
obj.Password = "zxcv9876"
obj.Port = 21
obj.Protocol = 2 ' ftpProtocolNormal
obj.CommandProtection = 1
obj.Passive = 1

' Connect
result = obj.Connect()
WScript.Echo "Connected " & result & vbCrLf


the connect log is showing

[20090212 19:13:19] SmartFTP FTP Library v1.5.17.15
[20090212 19:13:21] Resolving host name "xxx.xxx.xx.xx"
[20090212 19:13:21] Connecting to xxx.xx.xxx.xxx Port: 21
[20090212 19:13:21] Connected to xxx.xxx.xxx.xxx.
[20090212 19:13:21] 220-This System Is For Authorized Users Only.
[20090212 19:13:21] 220-
[20090212 19:13:21] 220 Secure FTP Server - SecureTransport 4.7 ready.
[20090212 19:13:21] AUTH TLS
[20090212 19:13:21] 234 SSLv23/TLSv1
[20090212 19:13:21] Connected. Exchanging encryption keys...
[20090212 19:13:21] An established connection was aborted by the software in your host machine.
[20090212 19:13:21] Server closed connection

Try SmartFTP and then post the log. What operating system are you using?

Regards,
Mat

I'm using Windows XP, Here's what shows up lin the log window

[09:55:52] SmartFTP v3.0.1024.32
[09:55:52] Resolving host name "xxx.xxx.xx.xx"
[09:55:52] Connecting to xxx.xxx.xx.xx Port: 21
[09:55:52] Connected to xxx.xxx.xx.xx.
[09:55:53] 220-This System Is For Authorized Users Only.
[09:55:53] 220-
[09:55:53] 220 Secure FTP Server - SecureTransport 4.7 ready.
[09:55:53] AUTH TLS
[09:55:53] 234 SSLv23/TLSv1
[09:55:53] Connected. Exchanging encryption keys...
[09:55:53] An established connection was aborted by the software in your host machine.
[09:55:53] Server closed connection
[09:55:53] Connect failed. Waiting to retry (30s)...

Hi,

I also tried to connect to "SmartFTP - FTPS" using the SMARTFTP Client and got the same results in the log file.

Are you using Windows Vista?

I am using Windows XP

Please try the latest version:
https://www.smartftp.com/download

I downloaded the new EXE and tried it. I got the following results the first time.


[13:10:47] SmartFTP v3.0.1026.2
[13:10:47] Resolving host name "205.174.34.41"
[13:10:47] Connecting to 205.174.34.41 Port: 21 [13:10:47] Connected to 205.174.34.41.
[13:10:47] 220-This System Is For Authorized Users Only.
[13:10:47] 220-
[13:10:47] 220 Secure FTP Server - SecureTransport 4.7 ready.
[13:10:47] AUTH TLS
[13:10:47] 234 SSLv23/TLSv1
[13:10:47] Connected. Exchanging encryption keys...
[13:11:48] Timeout (60s).
[13:11:48] Client closed the connection.
[13:11:48] Connect failed. Waiting to retry (30s)...


Now everytime I try it I get

[13:54:41] SmartFTP v3.0.1026.2
[13:54:41] Resolving host name "205.174.34.41"
[13:54:41] Connecting to 205.174.34.41 Port: 21
[13:54:41] Connected to 205.174.34.41.
[13:54:42] 220-This System Is For Authorized Users Only.
[13:54:42] 220-
[13:54:42] 220 Secure FTP Server - SecureTransport 4.7 ready.
[13:54:42] AUTH TLS
[13:54:42] 234 SSLv23/TLSv1
[13:54:42] Connected. Exchanging encryption keys...
[13:54:42] An established connection was aborted by the software in your host machine.
[13:54:42] Connect failed. Waiting to retry (30s)...
[13:54:42] Server closed connection

It looks like a SSL problem on the server side. Maybe you can get the log from the server and see why it disconnect the client (SmartFTP).

Regards,
Mat

Hi,

I talked to the guy who looks after the remote server. He's convinced that the CCC is not being sent. He even downloaded the SMARTFTP client and tried to get it to connect.

I'm not sure where to go from here. Any ideas?

thanks

The CCC command is sent after the secured connection is established. You need the logs from the server side to see why the server disconnects the client.