www.libssh2.org | Daily snapshots | Mailing list archive | Docs | Examples | github

Archive Index This month's Index

Subject: Re: [libssh2] #249: sftp download data corruption

Re: [libssh2] #249: sftp download data corruption

From: libssh2 Trac <trac_at_libssh2.stuge.se>
Date: Tue, 16 Oct 2012 22:23:05 -0000

#249: sftp download data corruption
---------------------+-------------------
  Reporter: maxmtl | Owner:
      Type: defect | Status: new
  Priority: normal | Milestone: 1.4.3
 Component: SFTP | Version: 1.4.2
Resolution: | Keywords:
Blocked By: | Blocks:
---------------------+-------------------

Comment (by bagder):

 That's a violation of the spec from the server's side.

 Both the -5 draft as well as the latest -13 draft mentions that it should
 not return more data than the 'length' as given in the SSH_FXP_READ
 packet.

 I would rather argue that when detecting that the data is larger than
 requested, it should probably bail out since there's no way for it to know
 what data it got and how to handle it. I think your fix is somewhat of a
 kludge that works for this particular broken server but we can't tell how
 other broken servers will respond with wrong sizes.

-- 
Ticket URL: <https://trac.libssh2.org/ticket/249#comment:1>
libssh2 <https://trac.libssh2.org/>
C library for writing portable SSH2 clients
_______________________________________________
libssh2-devel http://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel
Received on 2012-10-17

the libssh2 team