From dev-return-29379-apmail-mina-dev-archive=mina.apache.org@mina.apache.org Tue Dec 22 08:34:47 2015 Return-Path: X-Original-To: apmail-mina-dev-archive@www.apache.org Delivered-To: apmail-mina-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 2D17518406 for ; Tue, 22 Dec 2015 08:34:47 +0000 (UTC) Received: (qmail 56137 invoked by uid 500); 22 Dec 2015 08:34:47 -0000 Delivered-To: apmail-mina-dev-archive@mina.apache.org Received: (qmail 56071 invoked by uid 500); 22 Dec 2015 08:34:46 -0000 Mailing-List: contact dev-help@mina.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@mina.apache.org Delivered-To: mailing list dev@mina.apache.org Received: (qmail 56058 invoked by uid 99); 22 Dec 2015 08:34:46 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 22 Dec 2015 08:34:46 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 970AD2C1F4E for ; Tue, 22 Dec 2015 08:34:46 +0000 (UTC) Date: Tue, 22 Dec 2015 08:34:46 +0000 (UTC) From: =?utf-8?Q?Oliver_St=C3=B6neberg_=28JIRA=29?= To: dev@mina.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (SSHD-614) SCP upload fails with dropbear server (aka server with paket size limitation) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/SSHD-614?page=3Dcom.atlassian.j= ira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D150677= 49#comment-15067749 ]=20 Oliver St=C3=B6neberg commented on SSHD-614: --------------------------------------- I can't get it to work. I aways get org.apache.sshd.common.SshException: No more authentication methods availab= le Looking at the code it seems like password authentication is not yet implem= ented. Unfortunately I have no key file for the server I am testing against= and I cannot create one. > SCP upload fails with dropbear server (aka server with paket size limitat= ion) > -------------------------------------------------------------------------= ---- > > Key: SSHD-614 > URL: https://issues.apache.org/jira/browse/SSHD-614 > Project: MINA SSHD > Issue Type: Bug > Reporter: Oliver St=C3=B6neberg > Priority: Minor > Attachments: dropbear_not_working.log, openssh_working.log > > > When trying to upload a file via SCP to a server running dropbear I get t= he following error: > java.io.EOFException: readAck - EOF before ACK - =20 > at org.apache.sshd.common.scp.ScpHelper.readAck() in ScpHelper.java:703.= =20 > at org.apache.sshd.common.scp.ScpHelper.sendStream() in ScpHelper.java:53= 9.=20 > at org.apache.sshd.client.scp.DefaultScpClient.upload() in DefaultScpClie= nt.java:104.=20 > at org.apache.sshd.client.scp.AbstractScpClient.upload() in AbstractScpCl= ient.java:201.=20 > The main difference between dropbear and OpenSSH I have encountered is th= at dropbear has a paket size limitation in place by default. That's the rea= son in the first place why I even need to upload files via SCP since using = trying to execute bigger scripts via an exec channel it will fail. I attach= ed logs from the system that fails and another system. The main difference = seems to be this: > working (OpenSSH): > DEBUG [sshd-SshClient[51a8313b]-nio2-thread-9] (AbstractConnectionService= .java:236) channelOpenConfirmation(ChannelExec[id=3D0, recipient=3D-1]-Clie= ntSessionImpl[sshtest@XXXXXXXXX.XXXX.XXX/XX.XX.XX.XXX:22]) Received SSH_MSG= _CHANNEL_OPEN_CONFIRMATION recipient=3D > DEBUG [sshd-SshClient[51a8313b]-nio2-thread-9] (AbstractChannel.java:121)= setRecipient(ChannelExec[id=3D0, recipient=3D-1]-ClientSessionImpl[sshtest= @XXXXXXXXX.XXXX.XXX/XX.XX.XX.XXX:22]) recipient=3D0 > DEBUG [sshd-SshClient[51a8313b]-nio2-thread-9] (Window.java:122) init(Cha= nnelExec[id=3D0, recipient=3D0]-ClientSessionImpl[sshtest@XXXXXXXXX.XXXX.XX= X/XX.XX.XX.XXX:22]: client remote window) size=3D0, max.=3D0, packet=3D3276= 8 > DEBUG [sshd-SshClient[51a8313b]-nio2-thread-9] (ChannelExec.java:47) doOp= en(ChannelExec[id=3D0, recipient=3D0]-ClientSessionImpl[sshtest@XXXXXXXXX.X= XXX.XXX/XX.XX.XX.XXX:22]) send SSH_MSG_CHANNEL_REQUEST exec command=3Dscp -= p -t -- /tmp/XXXXX_script.sh > not working (dropbear): > DEBUG [sshd-SshClient[11389053]-nio2-thread-7] (AbstractConnectionService= .java:236) channelOpenConfirmation(ChannelExec[id=3D0, recipient=3D-1]-Clie= ntSessionImpl[test@/XX.XX.XX.XXX:44]) Received SSH_MSG_CHANNEL_OPEN_CONFIRM= ATION recipient=3D > DEBUG [sshd-SshClient[11389053]-nio2-thread-7] (AbstractChannel.java:121)= setRecipient(ChannelExec[id=3D0, recipient=3D-1]-ClientSessionImpl[test@/X= X.XX.XX.XXX:44]) recipient=3D0 > DEBUG [sshd-SshClient[11389053]-nio2-thread-7] (Window.java:122) init(Cha= nnelExec[id=3D0, recipient=3D0]-ClientSessionImpl[test@/XX.XX.XX.XXX:44]: c= lient remote window) size=3D24576, max.=3D24576, packet=3D32759 > DEBUG [sshd-SshClient[11389053]-nio2-thread-7] (ChannelExec.java:47) doOp= en(ChannelExec[id=3D0, recipient=3D0]-ClientSessionImpl[test@/XX.XX.XX.XXX:= 44]) send SSH_MSG_CHANNEL_REQUEST exec command=3Dscp -p -t -- /tmp/XXXXX_sc= ript.sh > As you can see that's a min/max set for the not working dropbear. > There's also two typos in this log message (the additional whitespace at = "client local" and the period at "max": > DEBUG [forceDeviceActionAsync] (Window.java:122) init(ChannelExec[id=3D0,= recipient=3D-1]-ClientSessionImpl[test@/10.48.43.214:44]: client local wi= ndow) size=3D2097152, max.=3D2097152, packet=3D32768 > I am using the latest version of master. -- This message was sent by Atlassian JIRA (v6.3.4#6332)