:RemoteCommand()
Class
Syntax
:RemoteCommand(cHost, nPort, nTimeout, cUserName, cCommand) --> cResults
Parameters
|
|
cHost |
The fully-qualified domain name or IP address of the Remote Host to connect to. |
|
|
nPort |
The port number the remote server is listening on.
|
|
|
nTimeout |
The number of seconds to wait for a response before failing the operation.
|
|
|
cUserName |
Character String that specifies the user name to be used to authenticate the current client session. |
|
|
cCommand |
Specifies the command to execute on the remote server. |
Return
cResults. The result of cCommand passed to the remote server
If the Method fails, the return value is NIL.
Description
The Method establishes a connection with the specified server and executes a command on that system.
The application may read the standard output and write to the standard input of the program running
on the server.
This Method depends on what is called host equivalence. With host equivalence, the remote server considers the client to be equivalent to itself, and as long as the specified user exists on the remote host, the client is permitted to login or execute commands on behalf of the user without requiring a password. Host equivalence is configured by the server administrator.
Note that if configured improperly, host equivalence can introduce a significant security loophole. Refer to your UNIX system documentation for more information about host equivalence and the use of the various remote commands.
See Also