mina-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Roberto Deandrea (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (SSHD-848) Possible bug opening local port forwarding channel
Date Tue, 09 Oct 2018 12:24:00 GMT

    [ https://issues.apache.org/jira/browse/SSHD-848?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16643247#comment-16643247

Roberto Deandrea commented on SSHD-848:

Hi Lyor, I submitted a new pull request as you requested. [https://github.com/apache/mina-sshd/pull/68/commits/9f2d49a97963d9f4330d96578142d67e06b44c07]




> Possible bug opening local port forwarding channel
> --------------------------------------------------
>                 Key: SSHD-848
>                 URL: https://issues.apache.org/jira/browse/SSHD-848
>             Project: MINA SSHD
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Roberto Deandrea
>            Priority: Major
>         Attachments: testlpf.ko, testlpf.ok
> Hi , We found a possible bug opening a local port forwarding channel.
> Scenario : The SSH client and server are based on Apache SSHD 2.0.1. There is a FTP client
sending a file through a local port forwarding channel to a target server.
> The problem manifests when the SSH server is busy and returns the SSH_MSG_CHANNEL_OPEN_CONFIRMATION
with a some delay and the client is very fast to send only a few bytes on a local port forwarding
> The outcome is the FTP client is NOT able to send bytes through the channel to the target
> Into SSH client traces we see :
> org.apache.sshd.common.channel.WindowClosedException: Already closed: Window[client/remote](TcpipClientChannel[id=4,
> According to us there is a chance that if we don't AWAIT the local port forward channel
is TOTALLY opened, when the client is very fast to send bytes... it closes its connection,
ao the channel that is already closing prevents bytes to flow through the channel to the target
> We guess there is a code bug in *DefaultForwardingFilter.sessionCreated()* method.
> We add the following line at the end of the method and the problem seems definitely fixed.
>             *channel.getOpenFuture().await();*
> Please, can you troubleshoot this issue and comment about our potential code fix ?
> Thanks in advance.
> I attached  the files:
> testslpf.ko SSH client traces with original code and a failed attempt
> testslpf.ok SSH client traces with our code changes and a successful attempt

This message was sent by Atlassian JIRA

View raw message