[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Sample Code for SSH Port Forwarding Server


Hello,

On Tue, Oct 16, 2018 at 6:39 PM, <g4-lisz@xxxxxxxxxxxx> wrote:

> Hi
>
> I wanted to let you know that I have a working, very rough code for sshd,
> which accepts a local port forwarding and pipes it to stdout. I still have
> to add all the stuff for opening the net socket on the server side, and the
> polling for reading and writing back. But the first obstacle is overcome.
>

glad to hear that. Hope my code helped you - at least a bit ....

I remember the biggest pain when making HaaS-libssh work was to correctly
fill/implement the callbacks in the ssh_channel_callbacks_struct,
ssh_server_callbacks_struct
and ssh_callbacks_struct :-(
And the next hard thing was the 'main loop' with libssh events and polling
- lot of 'deadlocks' there .....

On the other hand, I have even prepared patch against libssh to
implement/support some sort of security/welcome banner, but haven't
convince myself yet to send it up.

Regards

Zdenek OGAR Skalak

Till
>
> On 01.10.2018 14:31, Stefano Mtangoo wrote:
>
> I mean port forwarding. I use alot of ssh and do a lot of port forwarding
> for database connections.  So wanted to code utility for helping me with
> that. It could be contributed then as a sample.
>
> On Sun, Sep 30, 2018, 19:38 <g4-lisz@xxxxxxxxxxxx> wrote:
>
>> Did you visit the GIT link of Zdenek? It seems that he got quite far with
>> building a server... Or you are referring to port forwarding only?
>>
>> Till
>>
>> On 30.09.2018 15:28, Stefano Mtangoo wrote:
>>
>> It'll be really great. Once I tried and got nowhere.
>>
>> On Sun, Sep 30, 2018, 11:26 Andreas Schneider <asn@xxxxxxxxxxxxxx> wrote:
>>
>>> On Thursday, September 27, 2018 6:06:11 PM CEST g4-lisz@xxxxxxxxxxxx
>>> wrote:
>>> > Thank you very much! This will help me a lot. I'll will try to do this
>>> > for Windows - wish me luck ;))
>>>
>>> It would be great if someone could contribute an example ;-)
>>>
>>>
>>>
>>>
>>
> On Sep 30, 2018 19:38, <g4-lisz@xxxxxxxxxxxx> wrote:
>
> Did you visit the GIT link of Zdenek? It seems that he got quite far with
> building a server... Or you are referring to port forwarding only?
>
> Till
>
> On 30.09.2018 15:28, Stefano Mtangoo wrote:
>
> It'll be really great. Once I tried and got nowhere.
>
> On Sun, Sep 30, 2018, 11:26 Andreas Schneider <asn@xxxxxxxxxxxxxx> wrote:
>
>> On Thursday, September 27, 2018 6:06:11 PM CEST g4-lisz@xxxxxxxxxxxx
>> wrote:
>> > Thank you very much! This will help me a lot. I'll will try to do this
>> > for Windows - wish me luck ;))
>>
>> It would be great if someone could contribute an example ;-)
>>
>>
>>
>>
>
>
>

Follow-Ups:
Re: Sample Code for SSH Port Forwarding Serverg4-lisz@xxxxxxxxxxxx
Archive administrator: postmaster@lists.cynapses.org