Subject: [ libssh2-Bugs-2854355 ] ssh daemon drops connection if file size 14MB or more

[ libssh2-Bugs-2854355 ] ssh daemon drops connection if file size 14MB or more

From: SourceForge.net <noreply_at_sourceforge.net>
Date: Tue, 05 Jan 2010 12:22:26 +0000

Bugs item #2854355, was opened at 2009-09-08 15:47
Message generated for change (Comment added) made by schmittty
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=703942&aid=2854355&group_id=125852

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: SCP
Group: v1.0 (example)
Status: Open
Resolution: Works For Me
Priority: 1
Private: No
Submitted By: Andre (schmittty)
Assigned to: Daniel Stenberg (bagder)
Summary: ssh daemon drops connection if file size 14MB or more

Initial Comment:
Hi!

Currently I have an issue to copy files bigger than 14MB from remote host to local host (this barrier might differ on other) if I use the libssh2 library via libssh2_scp_recv() api call. Smaller files less than 14 MB are copied without an issue from remote host to local host. Furthermore scp command from shell doesn't show any issue by copying files above 14MB size. For the test the attached source “scp.c” from the example/simple is used with small modification.

The if I look to the libssh2 debug information and tcp trace I see that the ssh daemon refuses the tcp connection by TCP RESET flag. Currently I don’t have further trace information from ssh daemon, about it this quite strange that the ssh daemon refuse the tcp connection when more bytes need to be exchanged between the peers.

I hope you can let me know root cause for the “scp - libssh2” issue.

System information:
- Sun Solaris Sparc 64-bit
- Openssl library is compiled with 64-bit (for sparcv9)
- libssh2 is compiled with 64-bit (with CFLAG=m64)
- libssh2 used Openssl library
- Issue is observed if files are exchanged on single machine and between two Sun Solaris machines.

Please let me know if you need further information.

Thanks for your help in advance.
 Andre

----------------------------------------------------------------------

>Comment By: Andre (schmittty)
Date: 2010-01-05 13:22

Message:
Official fix, Patch 143140-02, is released on SunSolve and ready for use.
Item will be closed.

----------------------------------------------------------------------

Comment By: Andre (schmittty)
Date: 2009-11-04 16:50

Message:
After awhile I received a positive response and temporary fix (SR#
71610828) from Sun. The fix works fine and now it is possible with the Sun
ssh daemon and libssh2 to copy bigger files.

Sun plans to provide this fix (interoperability fix) within the next two
weeks, in his next service release.

Problem report will be closed when the official fix from Sun is
available.

----------------------------------------------------------------------

Comment By: Daniel Stenberg (bagder)
Date: 2009-09-17 23:58

Message:
I rephrased the summary.

But still, this is the server dropping a connection that otherwise works
with other servers. I can't see how this isn't rather a server-side bug.

----------------------------------------------------------------------

Comment By: Andre (schmittty)
Date: 2009-09-09 11:16

Message:
In my case Sun Solaris SSH 1.1.1 is used, which might be based on OpenSSH
3.5p1 (based on information from opensolaris).

----------------------------------------------------------------------

Comment By: alamaison (alamaison)
Date: 2009-09-09 11:03

Message:
Which version of OpenSSH are you connecting to? It looks like you might be
suffering the following Solaris OpenSSH bug:
https://bugzilla.mindrot.org/show_bug.cgi?id=1131. Apparently, it's fixed
in v4.4.

HTH

Alex

----------------------------------------------------------------------

Comment By: Andre (schmittty)
Date: 2009-09-09 10:37

Message:
Yes, the original scp.c example shows the same behaviour.

Furthermore I analysed the ssh daemon debug information and saw several

"sshd[27686]: [ID 800047 auth.crit] fatal: buffer_append_space: alloc
10489856 not supported"

trace outputs before the ssh daemon (sun sshd version Sun_SSH_1.1.1) close
the tcp connection (respectively in the sshd trace prints "Calling cleanup"
and "channel_free").

Any idea what caused the ssh daemon to call buffer_append_space?

Thanks
 Andre

----------------------------------------------------------------------

Comment By: Daniel Stenberg (bagder)
Date: 2009-09-08 19:43

Message:
so does the UNMODIFIED scp.c example work?

----------------------------------------------------------------------

You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=703942&aid=2854355&group_id=125852
_______________________________________________
libssh2-devel http://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel
Received on 2010-01-05