libssh2_channel_direct_tcpip_ex.3 (1364B)
1.TH libssh2_channel_direct_tcpip_ex 3 "1 Jun 2007" "libssh2 0.15" "libssh2" 2.SH NAME 3libssh2_channel_direct_tcpip_ex - Tunnel a TCP connection through an SSH session 4.SH SYNOPSIS 5.nf 6#include <libssh2.h> 7 8LIBSSH2_CHANNEL * 9libssh2_channel_direct_tcpip_ex(LIBSSH2_SESSION *session, 10 const char *host, int port, 11 const char *shost, int sport); 12 13LIBSSH2_CHANNEL * 14libssh2_channel_direct_tcpip(LIBSSH2_SESSION *session, 15 const char *host, int port); 16.fi 17.SH DESCRIPTION 18\fIsession\fP - Session instance as returned by 19.BR libssh2_session_init_ex(3) 20 21\fIhost\fP - Third party host to connect to using the SSH host as a proxy. 22 23\fIport\fP - Port on third party host to connect to. 24 25\fIshost\fP - Host to tell the SSH server the connection originated on. 26 27\fIsport\fP - Port to tell the SSH server the connection originated from. 28 29Tunnel a TCP/IP connection through the SSH transport via the remote host to 30a third party. Communication from the client to the SSH server remains 31encrypted, communication from the server to the 3rd party host travels 32in cleartext. 33.SH RETURN VALUE 34Pointer to a newly allocated LIBSSH2_CHANNEL instance, or NULL on errors. 35.SH ERRORS 36\fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed. 37.SH SEE ALSO 38.BR libssh2_session_init_ex(3)