Get Connection Details

If you try to run two policies containing SSH objects at the same time, then unexpected errors can occur. For example, the first policy can send commands in the SSH session created by the second policy. These errors occur because a class which handles the SSH connection is static.

Determine if there is an active SSH connection and retrieve details about the active connection

If this Object is used in an Automation Manager Policy that attempts to connect to a target device that is configured to use only SSH-2, the Policy may fail as the connection can be refused due to an invalid server version string error. This error will not occur for target devices that are configured to use only SSH-1 or to use either SSH-1 or SSH-2.

Input Parameters

None

Output Parameters

Name Type Description

IO

String

Name of the IO Connection DLL of SSH connection to the remote device.

ExpectPattern

String

Set ExpectPattern of SSH session to the remote device (usually blank).

Cipher

String

Encryption type used in SSH connection to the remote device.

Mac

String

Message type for the encryption (usually hmac-md5).

ServerVersion

String

Version of SSH used by the connecting device.

ClientVersion

String

Version of SSH for the remote device to which the connection is made.

Host

String

Host name or IP of the remote device to which the connection is made.

HostKey

String

Key Name used in the connection to the remote device.

Port

Number

Port number used in the SSH connection.

Password

String

Password used to authenticate the remote session.

UserName

String

User Name used to authenticate the remote session.

Result

Number

Returns a success value of zero or any value other than zero to indicate failure.

Example Input Parameters

No input parameters required