Subject: Re: libssh2_channel_forward_accept never returns!

Re: libssh2_channel_forward_accept never returns!

From: Peter Stuge <>
Date: Tue, 7 Oct 2014 09:42:48 +0200

Otavio Augusto wrote:
> Today I started using libssh2 API, mainly to use tcp forward.
> So the first thing I did was compiling the tcpip-forward.c example.

Please read the RFCs so that you are sure what part of the protocol
you want to use. tcpip-forward is a particular message in the SSH2
protocol and I guess that what you actually want is direct-tcptp.

> All goes well until the execution stop at "Waiting for remote connection"
> print..
> So libssh2_channel_forward_accept nevers return .... the execution is
> stuk there forever.

What happens when you connect to the forwarded port on the remote side?

Received on 2014-10-07