SFTP packet size limited to 16k



Hi,

I've been wondering why I can not receive larger packets
than 16 kbytes at a time, even though I have set my
applications window size to 137072 bytes and max packet
size to 32768 bytes.

My application is using libssh2 0.12 and I'm interacting
with OpenSSH_4.2p1, OpenSSL 0.9.7f 22 Mar 2005

OpenSSH agrees with my window size:

debug1: server_input_channel_open: ctype session rchan 0 win 131072 max 32768

but I still get only 16k packets:

debug1: subsystem: exec() /usr/libexec/openssh/sftp-server
debug2: fd 8 setting O_NONBLOCK
debug3: fd 8 is O_NONBLOCK
debug2: channel 0: rcvd adjust 16195
debug2: channel 0: rcvd adjust 16128
....

and so on.

I can get command line tools (scp/sftp) to transfer up ~52k
packets easily. This has some impact on the overall
performance of my application.

--
remove -asdf and asdf- for email address

.