The SFTP Client tool runs a single SFTP session of up to 10 commands using public key authentication. Any standard SFTP commands can be used—check the documentation for your server to see which commands are available. Raw SFTP traffic is supplied as an output to the tool. Any failures during tool execution are reported as Quality Tasks. If failures occur, server connections are closed and tool execution terminates. The tool is a standard implementation of SFTP V3. 

Installation

This tool can be installed from the UI or the command line.

UI Installation

  1. Choose Parasoft> Preferences.
  2. In the System Properties preferences, click Add JARs.
  3. Browse to the sftpclient.jar file and click OK.
  4. Restart SOAtest/Virtualize.

Command Line Installation

Add the sftp.jar file to the system.properties.classpath property in your settings properties file. For example:

system.properties.classpath=<path to jar>/sftpclient.jar

Usage

The SFTP Client can be added as a standalone tool via the Add Test wizard or chained to the output of another tool via the Add Output wizard.

Configuration

You can configure the following settings.

Commands Settings

Home Directory

Defines the user's local home directory. This directory is not the same as the user's remote home directory, which is configured on the server side. If empty, the system's current user's home directory will be used.

Command #1 - #10

Specifies the series of SFTP commands to be performed during the SFTP session. The commands will be executed in the order in which they are listed here. They should be typed exactly as if they were being performed in an interactive SFTP console. At least one of these fields must be defined.

Connection Settings

HostDefines the hostname or IP address of the server. Default is localhost.
Port

Defines the port for connecting to the server. Default is 22.

User NameDefines the username for connecting to the server. If empty, the tool will remain disabled.
Key Store FileDefines the absolute path to the user’s private key file, which should be in PEM format. If empty, the tool will remain disabled.
Known Hosts FileDefines the absolute path to a known hosts file, which should be formatted as a standard OpenSSH known hosts file. If a known hosts file is defined, then strict host key checking will be enabled. If the host key is not found in the known hosts file, the connection to the server will be closed. If empty, strict host key checking will remain disabled.
TimeoutDefines how many seconds to wait to connect to the SSH server (as well as the underlying SFTP channel) before timing out and closing all connections. Default is 30 seconds.

Third-party Content

This plug-in includes items that have been sourced from third parties as outlined below.

Additional license details are available in this plugin's licenses folder.

  • No labels