View on
MetaCPAN is shutting down
For details read Perl NOC. After June 25th this page will redirect to
Greg Sabino Mullane > Net-SSH-Perl > Net::SSH::Perl::SSH1



Annotate this POD



New  24
Open  34
Stalled  1
View/Report Bugs
Source   Latest Release: Net-SSH-Perl-2.14


Net::SSH::Perl::SSH1 - SSH1 implementation


    use Net::SSH::Perl;
    my $ssh = Net::SSH::Perl->new($host, protocol => 1);


Net::SSH::Perl::SSH1 implements the SSH1 protocol. It is a subclass of Net::SSH::Perl, and implements the interface described in the documentation for that module. In fact, your usage of this module should be completely transparent; simply specify the proper protocol value (1) when creating your Net::SSH::Perl object, and the SSH1 implementation will be loaded automatically.

NOTE: Of course, this is still subject to protocol negotiation with the server; if the server doesn't support SSH1, there's not much the client can do, and you'll get a fatal error if you use the above protocol specification (1).


Net::SSH::Perl::SSH1 shares the interface described by Net::SSH::Perl. In addition, you can call the following "advanced" methods on a Net::SSH::Perl::SSH1 object, that do not apply to a regular Net::SSH::Perl object.


Sets the cipher for the SSH session $ssh to $cipher_name (which must be a valid cipher name), and turns on encryption for that session.


Returns the "send" cipher object. This is the object that encrypts outgoing data.

If it's not defined, encryption is not turned on for the session.


Returns the "receive" cipher object. This is the object that decrypts incoming data.

If it's not defined, encryption is not turned on for the session.

NOTE: the send and receive ciphers and two different objects, each with its own internal state (initialization vector, in particular). Thus they cannot be interchanged.

$ssh->compression([ $level ])

Without arguments, returns the current compression level for the session. If given an argument $level, sets the compression level and turns on compression for the session.

Note that this should not be used to turn compression off. In fact, I don't think there's a way to turn compression off. But in other words, don't try giving this method a value of 0 and expect that to turn off compression. It won't.

If the return value of this method is undefined or 0, compression is turned off.


Returns the session key, which is simply 32 bytes of random data and is used as the encryption/decryption key.


Please see the Net::SSH::Perl manpage for author, copyright, and license information.

syntax highlighting: