Connecting with SFTP Tasks
Tasks' connection parameters can be set in their own tab. The connection properties are used to establish the connection to the SFTP server. The SFTP Tasks share similar connection parameters, excluding ListFiles which don't have a buffer size parameter because it is not responsible for transferring files but only for the information of those files.
You can set the Connection timeout parameter which is used to stop the execution of the Task if the connection can't be established in the given time. Keep alive interval options enables the SFTP client to send keep alive packages to the server. The default value is -1 which means the keep alive is disabled. The Address field specifies the server which is to be connected to and the Port field specifies which port is to be used. Usually, with SFTP servers, the default port is 22.
You are able to choose the Authentication method that is used to authenticate to the server. Possible values are:
UsernamePassword - This is used when only the username and password are needed for authentication.
UsernamePrivateKeyFile - This is used when the authentication is performed with a private key file.
UsernamePrivateKeyString - This is used if the private key needs to be given in string format.
UsernamePasswordPrivateKeyFile - Same as UsernamePrivateKeyFile, but with the password.
UsernamePasswordPrivateKeyString - Same as UsernamePrivateKeyString, but with the password.
The Tasks' options are modified by the selection of the Authentication parameter and needed fields are added to the parameter if, for example, a private key needs to be added as a file or a string. When a private key is selected a passphrase field will also become visible for the passphrase of the private key.
The next parameter is the server fingerprint. This parameter can be used to ensure that the Task is connecting to the correct server. The Task checks that the fingerprint given by the server matches the one given by the user. If the fingerprints don't match the connection is not established. Referring to the server fingerprint, a host key algorithm can be chosen from the selector below the 'Server fingerprint' parameter. This will modify the server fingerprint's format to the chosen one. Note that if 'Any' is chosen, the Task will use choose the first possible algorithm which is used by the server.
A buffer size can be set to the Task. This will determine the size of the buffer when files are transferred. With bigger sized files a bigger sized buffer is recommended. This will usually improve the performance.
Lastly, you can set the Task to use keyboard interactive authentication. This authentication method is used by some servers and by enabling this feature the Task will give the password from the parameters when the server prompts the Task.
The next article is Introduction to DownloadFiles and UploadFiles Tasks