[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: 回复:HOW to use ssh_channel_open_reverse_forward function to implement a reverse tunnel?
[Thread Prev] | [Thread Next]
- Subject: Re: 回复:HOW to use ssh_channel_open_reverse_forward function to implement a reverse tunnel?
- From: Andreas Schneider <asn@xxxxxxxxxxxxxx>
- Reply-to: libssh@xxxxxxxxxx
- Date: Thu, 09 Apr 2020 08:52:23 +0200
- To: libssh <libssh@xxxxxxxxxx>
- Cc: 刘元哲 <945695107@xxxxxx>
On Wednesday, 8 April 2020 17:21:44 CEST 刘元哲 wrote: > Re-Update: > After compared the different result > between ssh_message_global_request_reply_success > before ssh_channel_open_reverse_forward or after it I > found ssh_channel_listen_forward want a reply, so if I reply it > immediately, the ssh client then said "ssh_global_request: Global request > tcpip-forward success"and can't > receive ssh_channel_open_reverse_forward request. Otherwise if I > choose to reply it after ssh_channel_open_reverse_forward, > the ssh_channel_listen_forward will hang there, continue wait > for the reply. I've never used that code, we don't have example code nor a test for it. So as always I would argue: Untested code is broken code. I think we need to implement a test to actually fix the code. However I don't have time for this. Contributions in this area are very welcome. See the server testing code Anderson implemented for a start. Best regards, Andreas -- Andreas Schneider asn@xxxxxxxxxxxxxx GPG-ID: 8DFF53E18F2ABC8D8F3C92237EE0FC4DCC014E3D
=?gb18030?b?u9i4tKO6ILvYuLSjukhPVyB0byB1c2Ugc3NoX2No?==?gb18030?b?YW5uZWxfb3Blbl9yZXZlcnNlX2ZvcndhcmQgZnVu?==?gb18030?b?Y3Rpb24gdG8gaW1wbGVtZW50IGEgcmV2ZXJzZSB0?==?gb18030?b?dW5uZWw/?= | "=?gb18030?b?wfXUqtXc?=" <945695107@xxxxxx> |
HOW to use ssh_channel_open_reverse_forward function to implement a reverse tunnel? | "=?gb18030?b?wfXUqtXc?=" <945695107@xxxxxx> |
=?gb18030?b?u9i4tKO6SE9XIHRvIHVzZSBzc2hfY2hhbm5lbF9v?==?gb18030?b?cGVuX3JldmVyc2VfZm9yd2FyZCBmdW5jdGlvbiB0?==?gb18030?b?byBpbXBsZW1lbnQgYSByZXZlcnNlIHR1bm5lbD8=?= | "=?gb18030?b?wfXUqtXc?=" <945695107@xxxxxx> |
=?gb18030?b?u9i4tKO6SE9XIHRvIHVzZSBzc2hfY2hhbm5lbF9v?==?gb18030?b?cGVuX3JldmVyc2VfZm9yd2FyZCBmdW5jdGlvbiB0?==?gb18030?b?byBpbXBsZW1lbnQgYSByZXZlcnNlIHR1bm5lbD8=?= | "=?gb18030?b?wfXUqtXc?=" <945695107@xxxxxx> |