CONNECT

LANSA Integrator

CONNECT

The CONNECT command starts a connection to the remote FTP server.

 

                                                            Required

  

 CONNECT ----- HOST ------------ host:port ------------------------>

 

                                                            Optional

 

           >-- SECURE ---------- *NO ------------------------------>

                                 *YES 

                                 *IMPLICIT

 

           >-- PROTECTION ------ *NO ------------------------------>

                                 *YES

 

           >-- PORT_ADDRESS ---- address -------------------------->

 

           >-- ENCODING -------- encoding ------------------------->

 

           >-- TIMEOUT --------- milliseconds ---------------------|

 

Keywords

HOST

Nominate a FTP server to connect to. The FTP server can be specified as an IP address, nnn.nnn.nnn.nnn:port, or a domain name.
If a port number is not supplied on an IP address the default value 21 is used unless the keyword SECURE (*IMPLICIT) is used in which case the default port value is 990.

SECURE

Indicates whether a secure control channel is required to protect FTP command information like user and password.

The default value *NO indicates a plain data connection is to be used.

A value of  *YES initially connects to the remote FTP server using a plain socket then changes to SSL/TLS connection using the AUTH subcommand.

A value of *IMPLICIT indicates a secure control channel directly to the SSL/TLS FTP server is required.

PROTECTION

The default option *NO indicates a clear data channel is required.

The alternative value, *YES, indicates the data channel is to be secure.

PORT_ADDRESS

The local IP address used by the PORT subcommand.

This keyword is not typically used but is available to indicate the IP address has been dynamically allocated, such as a PPP dialup connect after the JSM has been started.

ENCODING

The remote server path encoding. The default option is *DEFAULT.

TIMEOUT

The host connection timeout in milliseconds. The default is 0, which is an infinite timeout or an operating system timeout.

Examples

RDML

 

USE BUILTIN(JSM_COMMAND) WITH_ARGS('CONNECT HOST(ISERIES01)') TO_GET(#JSMSTS #JSMMSG)]

 

RDMLX

 

use builtin(jsmx_command) with_args(#jsmxhdle1 'connect host(iseries01)') to_get(#jsmxsts #jsmxmsg)