-
-
02 Nov 2014 23:29:26 UTC
- Distribution: Net-Proxy
- Module version: 0.13
- Source (raw)
- Browse (raw)
- Changes
- How to Contribute
- Repository
- Issues (4)
- Testers (8 / 82 / 0)
- Kwalitee
Bus factor: 1- % Coverage
- License: perl_5
- Activity
24 month- Tools
- Download (49.28KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
NAME
Net::Proxy::Connector::dual - Y-shaped Net::Proxy connector
DESCRIPTION
Net::Proxy::Connecter::dual is a Net::Proxy::Connector that can forward the connection to two distinct services, based on the client connection, before any data is exchanged.
CONNECTOR OPTIONS
This connector can only work as an
in
connector.The
server_first
andclient_first
options are required: they are hashrefs containing the options necessary to create twoout
Net::Proxy::Connector objects that will be used to connect to the requested service.The Net::Proxy::Connector::dual object decides between the two services by waiting during a short timeout. If the client sends some data directly, then it is connected via the
client_first
connector. Otherwise, at the end of the timeout, it is connected via theserver_first
connector.- host
-
The hostname on which the connector will listen for client connections. Default is
localhost
. - port
-
The port on which the connector will listen for client connections.
- server_first
-
Typically an
out
connector to a SSH server or any service that sends a banner line. - client_first
-
Typically an
out
connectrot to a web server or SSL server. - timeout
-
The timeout in seconds (can be decimal) to make a decision. Default is 1 second.
AUTHOR
Philippe 'BooK' Bruhat,
<book@cpan.org>
.ACKNOWLEDGMENTS
This module is based on a script named sslh, which I wrote with Frédéric Plé
<frederic.ple+sslh@gmail.com>
(who had the original insight about the fact that not all servers speak first on the wire).Frédéric wrote a C program, while I wrote a Perl script (based on my experience with connect-tunnel).
Now that
Net::Proxy
is available, I've ported the Perl script to use it.COPYRIGHT
Copyright 2006-2014 Philippe 'BooK' Bruhat, All Rights Reserved.
LICENSE
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
Module Install Instructions
To install Net::Proxy, copy and paste the appropriate command in to your terminal.
cpanm Net::Proxy
perl -MCPAN -e shell install Net::Proxy
For more information on module installation, please visit the detailed CPAN module installation guide.