|
|
|
|
|
- Properties specific to sshSession variables
- Authentication mode
- Using sshSession variables
sshSession (Variable type) In french: sshSession
The sshSession type is used to define the characteristics of a connection to an SSH server. The characteristics of this connection can be defined using different WLanguage properties. Note: For more details on the declaration of this type of variable and the use of WLanguage properties, see Declaring a variable. cMySession is sshSession
cMySession.Address = "127.0.0.1"
cMySession.Port = 22
cMySession.User = "login"
cMySession.UserPassword = "pass"
Properties Properties specific to sshSession variables The following properties can be used to define a connection to an SSH server: | | | Property name | Type used | Effect |
---|
Address | Character string | Address of the SSH server. This address can be specified as follows: - IP address in XXX.XXX.XXX.XXX format (125.5.110.100 for example).
- IP address containing the server name (e.g. SSHServer). This syntax is recommended.
| ConnectionTimeout | Integer or Duration | Connection timeout expressed in milliseconds (20 seconds by default, i.e. 20000 milliseconds). This property can correspond to: - an integer representing the number of milliseconds,
- a Duration variable,
- the duration in a readable format (e.g., 20 s or 20000 ms).
| New in version 2025KeepAliveInterval | Integer or Duration | Time between requests sent to keep the connection alive and check that the SSH server is still responding. If the SSH server shuts down unexpectedly while a long command initiated by SSHCommand is being executed, the keep alive functionality can detect the loss of connection between the application and the server. This property can correspond to: - an integer corresponding to the number of seconds,
- a Duration variable,
- the duration in a readable format (e.g., 20s or 20000 ms).
If this property is set to: - 0, the keep alive functionality will be disabled.
- less than 2 seconds, the duration will be set to 2 seconds for technical reasons.
| Port | Integer | Connection port (22 by default). | PrivateKey | Character string or Certificate variable | Name of the Certificate variable to be used or OpenSSH key files (for a private key-based authentication). If this property is set, authentication by key is performed: only the properties User, PrivateKey and PrivateKeyPassword are taken into account.. | PrivateKeyPassword | Character string or Secret string | Password of the key file (for a private-key based authentication). The PrivateKey property corresponds to the private key to be used.
New in version 2025Secret strings: The secret string can be of one of the following types: Ansi string - Latin, Ansi or Unicode string, Unicode string.. To learn more about secret strings and how to use the vault, see Secret string vault. | User | Character string | User name. | UserPassword | Character string or Secret string | User password (the User property corresponds to the user's name).
New in version 2025Secret strings: If you use the secret string vault, the type of secret string used for this parameter must be "Ansi or Unicode string". To learn more about secret strings and how to use the vault, see Secret string vault. |
Remarks Authentication mode Key-based authentication takes precedence over password-based authentication. Key-based authentication is used if: - the server supports this authentication mode.
- the PrivateKey property is specified.
Password-based authentication is used if: - the server supports this authentication mode.
- property UserPassword is set.
Using sshSession variables sshSession variables can be used with WLanguage functions: - standard syntax:
| | SSHCommand | Sends a command to an SSH server. The session is automatically started and closed as soon as the command is sent. | SSHConnectShell | Starts a new SSH session of "Shell" type. | SSHDisconnectShell | Closes an SSH session that was opened by SSHConnectShell. | SSHRead | Reads the data found on the output buffer of the SSH session. | SSHWrite | Writes data into the specified SSH session. |
- prefix syntax:
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|