Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)


Topic review


Re: Does version support FTP explicit TLS?

I'm not sure you can run compiled C# code against different version of the assembly. But I'm not SSIS expert. Shouldn't the WinSCP .NET assembly be part of your SSIS package? What does it even mean "the server has 5.7.7"? Are you referring to WinSCP or WinSCP .NET assembly? Aren't you relying on the installed version of WinSCP.exe? You should not. Deploy your own version with your SSIS package.

Re: Does version support FTP explicit TLS?

Thanks Martin, it worked
My SSIS package was developed with the latest version of WinSCP. But the server has 5.7.7. Do you think my SSIS c# code will work on the server?
SessionOptions sessionOptions = new SessionOptions
    Protocol = Protocol.Ftp,
    HostName = (string)Dts.Variables["User::HostName"].Value,
    UserName = (string)Dts.Variables["User::UserName"].Value,
    Password = (string)Dts.Variables["User::Password"].Value,
    FtpSecure = FtpSecure.Explicit,
sessionOptions.AddRawSettings("AddressFamily", "1");
sessionOptions.AddRawSettings("MinTlsVersion", "12");
using (Session session = new Session())
    session.ExecutablePath = (string)Dts.Variables["User::WinSCPexePath"].Value;
    // Connect
    // Upload files
    TransferOptions transferOptions = new TransferOptions();
    transferOptions.TransferMode = TransferMode.Binary;
    TransferOperationResult transferResult = session.PutFiles(
        (string)Dts.Variables["User::LocalFilePath"].Value + (string)Dts.Variables["User::LocalFileName"].Value,
         true, transferOptions);
    // Throw on any error

Re: Does version support FTP explicit TLS?

You should not use 5.7.7. It's over 5 years old.

Anyway, 5.7.7 supports the FTP with an explicit TLS encryption. But it does not support the ftpes prefix. Instead, use ftp and add -explicit switch. See help open.

Does version support FTP explicit TLS?

Apologies if this is documented somewhere. In version is the following supported: /command "open ftpes://|"