Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add support for OpenSSH "limits" extension
This commit adds client and server support for the OpenSSH "limits" extension, which allows the client to query server limits such as the maximum supported read and write size, improving performance between clients and servers that can support larger sizes. When AsyncSSH is acting as a server, it advertises support for up to 4 MiB reads and write, and a large enough packet size to hold such write requests. As a client, it will query these values from servers supporting the extension and automatically default to the largest supported size. When a server does not support this extension, AsyncSSH will fall back to a "safe" maxmium size of 16 KiB for both reads and writes. SCP has also been adjusted from a default size of 16 KiB to 256 KiB, which seemed to be the sweet spot after some local performance testing. As before, callers can always choose to override this default with the block_size parameter on calls to open() or to the higher-level get/put/copy functions, but generally speaking this should not be necessary.
- Loading branch information