[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Reading multiple channels under the same session
[Thread Prev] | [Thread Next]
- Subject: Re: Reading multiple channels under the same session
- From: g4-lisz@xxxxxxxxxxxx
- Reply-to: libssh@xxxxxxxxxx
- Date: Wed, 30 Jan 2019 00:18:20 +0100
- To: libssh@xxxxxxxxxx
On 29.01.19 23:23, Alberto Garcia wrote: > Hi, > > First of all I want to clarify that I'm doing my tests in Windows so I > had to adapt the code to work in it (I modified the minimum possible > from your code). I'm worried that the problem may be in the windows > support of libssh. > > I've been able to reproduce in a "consistent" way the crash. I wrote a > simple python code that in 5 threads uses the proxy socks to do > requests and it crashes immediately. It ALWAYS crashes > within cb_readsock but at different places in it which makes me think > that is a race condition of some sort which is weird because I'm only > threading at ssh_bind_accept(). > > If there is anything that comes to your mind please let me know. > That's interesting! I always wanted to make it work on Windows, but I did not find the time to get into all this Visual Studio stuff... I'm a Linux guy ;-) You also compiled libssh by yourself, or you downloaded it from somewhere? On Linux my code is working - At least I tested it with 5 parallel channels over one session with OpenSSH client: ssh -v -v -p2022 -N myuser@localhost -L8088:somedomain.com:80 The problem is to find a website which does not send redirects or has a baseurl tag. I used the site of a client, so I had to remove the name here. But as you can see there are a few channels open simultaneously: debug1: Connection to port 8088 forwarding to XXXXXXX port 80 requested. debug2: fd 11 setting TCP_NODELAY debug2: fd 11 setting O_NONBLOCK debug1: channel 6: new [direct-tcpip] debug1: Connection to port 8088 forwarding to XXXXXXX port 80 requested. debug2: fd 12 setting TCP_NODELAY debug2: fd 12 setting O_NONBLOCK debug1: channel 7: new [direct-tcpip] debug2: channel 4: open confirm rwindow 32000 rmax 35000 debug2: channel 5: open confirm rwindow 32000 rmax 35000 debug2: channel 6: open confirm rwindow 32000 rmax 35000 debug2: channel 7: open confirm rwindow 32000 rmax 35000 debug2: channel 3: rcvd adjust 1248429 debug2: channel 4: rcvd adjust 1248438 debug2: channel 5: rcvd adjust 1248443 debug2: channel 6: rcvd adjust 1248435 debug2: channel 7: rcvd adjust 1248429 debug2: channel 4: window 1997957 sent adjust 99195 debug2: channel 5: window 1998454 sent adjust 98698 debug2: channel 4: window 1992032 sent adjust 105120 debug2: channel 2: rcvd eof debug2: channel 2: output open -> drain debug2: channel 2: obuf empty debug2: channel 2: close_write debug2: channel 2: output drain -> closed debug2: channel 2: rcvd close debug2: channel 2: close_read debug2: channel 2: input open -> closed debug2: channel 2: send close debug2: channel 2: is dead debug2: channel 2: garbage collecting I will stresstest this code a bit further tomorrow. Regards, Till
Reading multiple channels under the same session | Alberto Garcia <agarciaillera@xxxxxxxxx> |
Re: Reading multiple channels under the same session | g4-lisz@xxxxxxxxxxxx |
Re: Reading multiple channels under the same session | Alberto Garcia <agarciaillera@xxxxxxxxx> |
Re: Reading multiple channels under the same session | g4-lisz@xxxxxxxxxxxx |
Re: Reading multiple channels under the same session | Alberto Garcia <agarciaillera@xxxxxxxxx> |
Re: Reading multiple channels under the same session | Alberto Garcia <agarciaillera@xxxxxxxxx> |
Re: Reading multiple channels under the same session | g4-lisz@xxxxxxxxxxxx |
Re: Reading multiple channels under the same session | Alberto Garcia <agarciaillera@xxxxxxxxx> |
Re: Reading multiple channels under the same session | g4-lisz@xxxxxxxxxxxx |
Re: Reading multiple channels under the same session | Alberto Garcia <agarciaillera@xxxxxxxxx> |