Subject: Re: LIBSSH2_SFTP_PACKET_MAXLEN

Re: LIBSSH2_SFTP_PACKET_MAXLEN

From: Henrik Nordström <henrik_at_henriknordstrom.net>
Date: Sun, 13 Nov 2011 20:42:14 +0100

sön 2011-11-13 klockan 18:58 +0100 skrev Daniel Stenberg:

> There's no negotiation, no. There's just that maximum packet size description
> from the spec.

Just read the spec again, and there is negotiation.

There is negotiation at the channel level with a dual-sided "I can
receive packets up to X in size" per channel request. Clean and nice.
Restricted by the available channel window size which adds a bit of
mess. This is at the channel level so transport packet size is a bit
bigger than this.

At transport level there is a minimum Maximum Packet Size all must
support receiveing, which MAY be exceeded if needed.

There is no specificed hard limit of the overhead added at transport
level, which makes transport packet size limit somewhat arbitrary when
larger packet sizes are negotiated. But I guess it's fine as long as one
stays well within maximum_packet_size+(35000-32768) at transport level,
where maximum_packet_size is actually maximum transport payload size.

Regards
Henrik

_______________________________________________
libssh2-devel http://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel
Received on 2011-11-13