Reading Time: 8 minutes

Introduction:

File Transfer Protocol (FTP) is one of the most common and economically used EDI communication protocol standards. It is used to exchange EDI files between sender and receiver over TCP/IP network based servers.

FTP Connection details:

Initially, in EDI message exchange, if FTP is chosen as a communication protocol, the FTP account should be verified if it will be hosted at the Sender server or will it be hosted at the Receiver server. For both the types, the below set of information must be collated.

FTP Details Test Environment PRD environment
Host Name < Test FTP Server Domain Name > < PRD FTP Server Domain Name >
(Bunch of) IP Address Set of Test FTP Server IP address Set of PRD FTP Server IP address
User Name < Test FTP Server User Name > < PRD FTP Server User Name >
Password < Test FTP Server Pass Auth > < PRD FTP Server Pass Auth >
Port No < Test FTP Server Port No > < PRD FTP Server Port No >
Folder Details Separate Folder - Inbound Flows
Separate Folder - Outbound Flows
Separate Folder - Inbound Flows
Separate Folder - Outbound Flows

Best Practices in EDI FTP communication protocol:

    • It is highly recommended to use Host/Domain Name rather than IP address as if one of the IP addresses is down due to planned/unplanned maintenance, then when using host names it automatically switches to the next active IP address bound inside domain name and provides continuous connection.
    • It is worth having two separate FTP server connections, one for Test and another for PRD. However, if there are IT budget constraints, we can differentiate Test and PRD server connections by having separate folders

        Ex: /test/in – Inbound flows Test env
              /test/out – Outbound flows Test env
              /in – Inbound flows PRD env
             /out – Outbound flows PRD env

Once the FTP connection is established, the data can be transferred in following four data representations: 

      • ASCII mode – Data is converted into “8-bit ASCII”, but it is not suitable for data other than plain text.
      • IMAGE mode – It is called binary mode, used in transferring images, the data are sent in binary form byte by byte, the receiver receives that byte-stream and stores it in sync with receiving.
      • EBCDIC Mode – It is used for plain text between hosts using the EBCDIC character set. These character sets are not easily readable. You need an EBCDIC to ASCII converter to read the data. Mainly used while connecting to legacy mainframe computers.
      • Local Mode – It allows two machines that have identical setup, transfer data without converting into ASCII (in a proprietary format).

The data transfer can happen in either of the following three modes:

      • Stream Mode – In this mode data is sent as a continuous stream without any processing at the FTP. Instead, the processing of data is done at the TCP layer.
      • Block Mode – In this mode, FTP breaks data into blocks and passes those blocks to the TCP layer.
      • Compressed Mode –  In this mode, the data is first compressed using a compression algorithm before passing to the TCP layer. 

FTP sessions work in active or passive modes:

      • Active mode: After a Sender system initiates a session via a command channel request, the receiver creates a data connection back to the sender and begins transferring data. In active mode, the sender FTP server is responsible for opening the listening port.
      • Passive mode: The receiver uses the command channel to send the sender the information it needs to open a data channel. Because the passive mode has the client initiating all connections, it works well across firewalls and network address translation gateways. In passive mode, the Receiver FTP system is responsible for opening the listening port.

Pros and Cons for  Active & Passive Mode:

      • Active FTP might cause issues because of Firewalls whereas Passive mode doesn’t.
      • Relatively secure mode in Active FTP connection as only Port ‘21’ will be used, whereas the admin team has to open a range of dynamic ports in Passive mode which makes itself less secure.
      • For “active” FTP, the sender FTP server connected from the internet, for passive ftp, the complete load is on the receiver FTP server.

FTP Communication Protocol Testing:

If FTP is hosted within Sender’s server, this FTP communication protocol testing is not needed. This step can be recommended to the receiver in order to verify whether our shared FTP connection parameters are working.

However, if the FTP server is hosted on the receiver’s server, this step is recommended to perform.

For testing FTP communication through EDI flows, we should have two items ready: Prepare a standalone flow and a listener.

For sending files from Sender FTP server to receiver, we need a FTP Push and for grabbing files from the receiver’s FTP server to sender, we need a FTP Pull.

“FTP push” – If we are successful enough to send files to the receiver FTP server – directory, then this FTP communication testing is successful. There are multiple ways this testing can fail. However, I wanted to share an interesting point at this juncture. If we are able to login into FTP server and can’t deliver files to the designated directory, then the particular user name was not given full permissions to grab the files. We have to check with the receiver IT team to grant as necessary permissions.

“FTP Pull” – If we have received files by pointing our FTP listener job to pull files from the right FTP direct.

    Advantages of FTP(File Transfer Protocol):

      • Speed is one of the advantages of FTP(File Transfer Protocol).
      • File sharing also comes in the category of advantages of FTP in that between two machine files can be shared on the network.
      • Efficiency is more in FTP.

    Disadvantages of FTP(File Transfer Protocol):

      • The File size limit is the drawback of FTP; only 2 GB size files can be transferred.
      • Multiple receivers are not supported by the FTP.
      • FTP does not encrypt the data; this is one of the biggest drawbacks of FTP.

    Our flexible EDI solutions can meet all the communication protocol requirements of your partners and your business for effective processing of transactions.

    Quick Call
    close slider

      Quick Call
      A SMI Expert will get in touch with you shortly