GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
Net::SSH::Perl::Subsystem::Client(3) User Contributed Perl Documentation Net::SSH::Perl::Subsystem::Client(3)

Net::SSH::Perl::Subsystem::Client - Subsystem client base class

    package My::Subsystem;

    use Net::SSH::Perl::Subsystem::Client;
    @ISA = qw( Net::SSH::Perl::Subsystem::Client );

    use constant MSG_HELLO => 1;

    sub init {
        my $system = shift;
        $system->SUPER::init(@_);

        my $msg = $system->new_msg(MSG_HELLO);
        $msg->put_str("Hello, subsystem server.");
        $msg->send;
    }

    sub subsystem { "mysubsystem" }

Net::SSH::Perl::Subsystem::Client simplifies the process of writing a client for an SSH-2 subsystem. A subsystem is generally a networking protocol that is built on top of an SSH channel--the channel provides transport, connection, encryption, authentication, message integrity, etc. The subsystem client and server communicate over this encrypted, secure channel (a channel built over an insecure network). SSH provides the encrypted transport, and the subsystem is then free to act like a standard networking protocol.

Subsystem::Client is built on top of Net::SSH::Perl, which provides the client end of the services described above (encryption, message integrity checking, authentication, etc.). It is designed to be used with a subsystem server, working with respect to an agreed-upon networking protocol.

SFTP is an example of a subsystem: the underlying transport is set up by Net::SSH::Perl, and on top of that layer, files can be transferred and filesystems managed without knowledge of the secure tunnel.

Net::SSH::Perl::Subsystem::Client is intended to be used as a base class for your protocol-specific client. It handles all interaction with Net::SSH::Perl so that your focus can be on sending commands to the subsystem server, etc.

Your subclass will probably be most interested in using and/or overriding the following methods:

Initializes a new Subsystem::Client object: builds the SSH tunnel using Net::SSH::Perl, then opens up a channel along which the subsystem traffic will be sent. It then opens a connection to the subsystem server.

You can override this method to provide any additional functionality that your client might need; for example, you might wish to use it to send an 'init' message to the subsystem server.

2017-03-12 perl v5.32.1

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.