Question
· Sep 26, 2019

FTP(S) Outbound Adapter disconnecting

Hi community, 

I created a business operation class using the FTP Outbound Adapter, and it works when configured for SFTP but when I try to use it for FTPS, it does not work as expected.  The connection is established, it creates the file on the destination server but then is disconnected in the middle of the transfer and the PutStream returns 0 and never seems to finish the write of the file.  Anyone have any idea of what's happening or any steps I can try to troubleshoot?  

Thanks in advance.

 

Info:

Connected to FTP Server '<server>:<port>/<user>/SSL='Generic_FTPS_SSL/TSL*'
at path '/'
using Credentials '<credentials>'

 

Error:

 

ERROR <Ens>ErrException: <WRITE>zgenericStore+36 ^%Net.FtpSession.1 -- logged as '-'
number - @''

 

Info:

Disconnecting from <server>

 

Trace:

Return Status from PutStream is 0 Ú<Ens>ErrException/<WRITE>zgenericStore+36 ^%Net.FtpSession.1 -- -- @''…<PRODUCTION>n"e ^zEnsError+1^Ens.Util.Error.1 ^1(e^zEnsSystemError+6 ^Ens.Util.Error.1^10e ^zPutStream+13^EnsLib.FTP.OutboundAdapter.1 ^2-e^zOnMessage+36 ^<OperationClass>.1 ^1/e^zMessageHandler+5 ^Ens.BusinessOperation.1 ^18e^zMessageHeaderHandler+23 ^<CustomOperationClass>
.1 ^1e^zOnTask+42^Ens.Host.1 ^1e^zStart+62^Ens.Job.1 ^2$d^StartEnsembleJob+6 ^|"%SYS"|STU^1d^ ^^0 of putting file: /HelloWorld.txt
Discussion (2)0
Log in or sign up to continue

Worked with the WRC and we identified the following configurations/changes were required to resolve this issue:

  1. Specify the SSLConfig setting in Ensemble
    1.  Had to include a * in the setting for legacy FTPS (otherwise it would not connect at all)
  1. Ensemble does not support session resumption (if required by the vendor hosting the server). 
    1. Reached out to vendor for them to disable it.
    2. Additionally there were two FTP commands that needed to be sent PBSZ 0 (Protection Buffer Size) and PROT P (Protection Data Channel).  These need to be run after the connection is made but before the write/save of the file on the server.

                                do ..Adapter.Connect()

                                do ..Adapter.FTP.sendCommand("PBSZ 0")
                                do ..Adapter.FTP.sendCommand("PROT P")

 

Thanks

How did you implement the 2nd part of this?

    1. Additionally there were two FTP commands that needed to be sent PBSZ 0 (Protection Buffer Size) and PROT P (Protection Data Channel).  These need to be run after the connection is made but before the write/save of the file on the server.

                                do ..Adapter.Connect()

                                do ..Adapter.FTP.sendCommand("PBSZ 0")
                                do ..Adapter.FTP.sendCommand("PROT P")