Class: Net_SSH1
Source Location: /lib/3rdParty/phpseclib/Net/SSH1.php
Pure-PHP implementation of SSHv1.
Author(s):
Version:
|
|
Class Details
Class Methods
constructor Net_SSH1 [line 392]
Net_SSH1 Net_SSH1(
String
$host, [optional
$port = 22], [optional
$timeout = 10], [optional
$cipher = NET_SSH1_CIPHER_3DES])
|
|
Default Constructor. Connects to an SSHv1 server
Tags:
Parameters:
destructor __destruct [line 783]
Destructor. Will be called, automatically, if you're supporting just PHP5. If you're supporting PHP4, you'll need to call disconnect().
Tags:
method disconnect [line 770]
method exec [line 610]
Executes a command on a non-interactive shell, returns the output, and quits. An SSH1 server will close the connection after a command has been executed on a non-interactive shell. SSH2 servers don't, however, this isn't an SSH2 client. The way this works, on the server, is by initiating a shell with the -s option, as discussed in the following links: http://www.faqs.org/docs/bashman/bashref_65.html http://www.faqs.org/docs/bashman/bashref_62.html To execute further commands, a new Net_SSH1 object will need to be created. Returns false on failure and the output, otherwise.
Tags:
Parameters:
method getHostKeyPublicExponent [line 1097]
String getHostKeyPublicExponent(
[optional
$raw_output = false])
|
|
Return the host key public exponent Returns, by default, the base-10 representation. If $raw_output is set to true, returns, instead, the raw bytes. This behavior is similar to PHP's md5() function.
Tags:
Parameters:
method getHostKeyPublicModulus [line 1112]
String getHostKeyPublicModulus(
[optional
$raw_output = false])
|
|
Return the host key public modulus Returns, by default, the base-10 representation. If $raw_output is set to true, returns, instead, the raw bytes. This behavior is similar to PHP's md5() function.
Tags:
Parameters:
method getServerIdentification [line 1155]
String getServerIdentification(
)
|
|
Return the server identification.
Tags:
method getServerKeyPublicExponent [line 1067]
String getServerKeyPublicExponent(
[optional
$raw_output = false])
|
|
Return the server key public exponent Returns, by default, the base-10 representation. If $raw_output is set to true, returns, instead, the raw bytes. This behavior is similar to PHP's md5() function.
Tags:
Parameters:
method getServerKeyPublicModulus [line 1082]
String getServerKeyPublicModulus(
[optional
$raw_output = false])
|
|
Return the server key public modulus Returns, by default, the base-10 representation. If $raw_output is set to true, returns, instead, the raw bytes. This behavior is similar to PHP's md5() function.
Tags:
Parameters:
method getSupportedAuthentications [line 1144]
Array getSupportedAuthentications(
[optional
$raw_output = false])
|
|
Return a list of authentications supported by SSH1 server. Just because a cipher is supported by an SSH1 server doesn't mean it's supported by this library. If $raw_output is set to true, returns, instead, an array of constants. ie. instead of array('password authentication'), you'll get array(NET_SSH1_AUTH_PASSWORD).
Tags:
Parameters:
method getSupportedCiphers [line 1128]
Array getSupportedCiphers(
[optional
$raw_output = false])
|
|
Return a list of ciphers supported by SSH1 server. Just because a cipher is supported by an SSH1 server doesn't mean it's supported by this library. If $raw_output is set to true, returns, instead, an array of constants. ie. instead of array('Triple-DES in CBC mode'), you'll get array(NET_SSH1_CIPHER_3DES).
Tags:
Parameters:
method interactiveRead [line 743]
String interactiveRead(
)
|
|
Reads the output of an interactive shell. Requires PHP 4.3.0 or later due to the use of the stream_select() function. If you see stuff like "[00m", you're seeing ANSI escape codes. According to How to Enable ANSI.SYS in a Command Window, "Windows NT does not support ANSI escape sequences in Win32 Console applications", so if you're a Windows user, there's not going to be much recourse.
Tags:
method interactiveWrite [line 708]
Boolean interactiveWrite(
String
$cmd)
|
|
Inputs a command into an interactive shell.
Tags:
Parameters:
method login [line 547]
Boolean login(
String
$username, [optional
$password = ''])
|
|
Login
Tags:
Parameters:
|
|