./security/py-asyncssh, Asynchronous SSHv2 client and server library

[ CVSweb ] [ Homepage ] [ RSS ] [ Required by ] [ Add to tracker ]

Branch: CURRENT, Version: 2.4.2, Package name: py37-asyncssh-2.4.2, Maintainer: pkgsrc-users

AsyncSSH is a Python package which provides an asynchronous client and server
implementation of the SSHv2 protocol on top of the Python 3.4+ asyncio

Required to run:
[security/py-OpenSSL] [devel/py-setuptools] [security/py-cryptography] [security/py-bcrypt] [security/py-gssapi] [lang/python37]

Required to build:

Master sites:

SHA1: 2e96023f03a5e616e7825dce7f092bbd351f4843
RMD160: 1df437e245fc5cc7a25af8527f2a8c79137b774b
Filesize: 400.188 KB

Version history: (Expand)

CVS history: (Expand)

   2020-09-14 09:40:08 by Adam Ciarcinski | Files touched by this commit (3) | Package updated
Log message:
py-asyncssh: updated to 2.4.2

Release 2.4.2
Fixed a potential race condition when receiving EOF right after a channel is opened.
Fixed a couple of issues related to the error_handler and progress_handler \ 
callbacks in AsyncSSH SFTP/SCP.
Fixed a couple of issues related to using pathlib objects with AsyncSSH SCP.
Release 2.4.1
Fixed SCP server to send back an exit status when closing the SSH channel, since \ 
the OpenSSH scp client returns this status to the shell which executed it.
Fixed listeners created by forward_local_port(), forward_local_path(), and \ 
forward_socks() to automatically close when the SSH connection closes, \ 
unblocking any wait_closed() calls which are in progress.
Fixed a potential exception that could trigger when the SSH connection is closed \ 
while authentication is in progress.
Fixed tunnel connect code to properly clean up an implicitly created tunnel when \ 
a failure occurs in trying to open a connection over that tunnel.

Release 2.4.0
Added support for accessing keys through a PKCS#11 provider, allowing keys on \ 
PIV security tokens to be used directly by AsyncSSH without the need to run an \ 
SSH agent. X.509 certificates can also be retrieved from the security token and \ 
used with SSH servers which support that.
Added support for using Ed25519 and Ed448 keys in X.509 certificates, and the \ 
corresponding SSH certificate and signature algorithms. Certificates can use \ 
these keys as either subject keys or signing keys, and certificates can be \ 
generated by either AsyncSSH or by OpenSSL version 1.1.1 or later.
Added support for feed_data() and feed_eof() methods in SSHReader, mirroring \ 
methods of the same name in asyncio’s StreamReader to improve interoperability \ 
between the two APIs.
Updated unit tests to test interoperability with OpenSSL 1.1.1 when reading and \ 
writing Ed25519 and Ed448 public and private key files. Previously, due to lack \ 
of support in OpenSSL, AsyncSSH could only test against OpenSSH, and only in \ 
OpenSSH key formats. With OpenSSL 1.1.1, testing is now also done using PKCS#8 \ 
Fixed config file parser to properly ignore all comment lines, even if the lines \ 
contain unbalanced quotes.
Removed a note about the lack of a timeout parameter in the AsyncSSH connect() \ 
method, now that it supports a login_timeout argument.
   2020-07-27 19:32:51 by Adam Ciarcinski | Files touched by this commit (3) | Package updated
Log message:
py-asyncssh: updated to 2.3.0

Release 2.3.0
Added initial support for reading configuration from OpenSSH-compatible config \ 
files, when present. Both client and server configuration files are supported, \ 
but not all config options are supported. See the AsyncSSH documentation for the \ 
latest list of what client and server options are supported, as well as what \ 
match conditions and percent substitutions are understood.
Added support for the concept of only a subset of supported algorithms being \ 
enabled by default, and for the ability to use wildcards when specifying \ 
algorithm names. Also, OpenSSH’s syntax of prefixing the list with ‘^’, \ 
‘+’, or ‘-‘ is supported for incrementally adjusting the list of \ 
algorithms starting from the default set.
Added support for specifying a preferred list of client authentication methods, \ 
in order of preference. Previously, the order of preference was hard-coded into \ 
Added the ability to use AsyncSSH’s “password” argument on servers which \ 
are using keyboard-interactive authentication to prompt for a “passcode”. \ 
Previously, this was only supported when the prompt was for a “password”.
Added support for providing separate lists of private keys and certificates, \ 
rather than requiring them to be specifying together as a tuple. When this new \ 
option is used, AsyncSSH will automatically associate the private keys with \ 
their corresponding certificates if matching certificates are present in the \ 
Added support for the “known_hosts” argument to accept a list of known host \ 
files, rather than just a single file. Known hosts can also be specified using \ 
the GlobalKnownHostFile and UserKnownHostFile config file options, each of which \ 
can take multiple filenames.
Added new “request_tty” option to provide finer grained control over whether \ 
AsyncSSH will request a TTY when opening new sessions. The default is to still \ 
tie this to whether a “term_type” is specified, but now that can be \ 
overridden. Supported options of “yes”, “no”, “force”, and \ 
“auto” match the values supported by OpenSSH.
Added new “rdns_lookup” option to control whether the server does a reverse \ 
DNS of client addresses to allow matching of clients based on hostname in \ 
authorized keys and config files. When this option is disabled (the default), \ 
matches can only be based on client IP.
Added new “send_env” argument when opening a session to forward local \ 
environment variables using their existing values, augmenting the “env” \ 
argument that lets you specify remote environment variables to set and their \ 
corresponding values.
Added new “tcp_keepalive” option to control whether TCP-level keepalives are \ 
enabled or not on SSH connections. Previously, TCP keepalives were enabled \ 
unconditionally and this is still the default, but the new option provides a way \ 
to disable them.
Added support for sending and parsing client EXT_INFO messages, and for sending \ 
the “global-requests-ok” option in these messages when AsyncSSH is acting as \ 
a client.
Added support for expansion of ‘~’ home directory expansion when specifying \ 
arguments which contain filenames.
Added support for time intervals and byte counts to optionally be specified as \ 
string values with units, allowing for values such as “1.5h” or “1h30m” \ 
instead of having to specify that as 5400 seconds. Similarly, a byte count of \ 
“1g” can be passed to indicate 1 gigabyte, rather than specifying 1073741824 \ 
Enhanced logging to report lists of sent and received algorithms when no \ 
matching algorithm is found. Thanks go to Jeremy Schulman for suggesting this.
Fixed an interoperability issue with PKIXSSH when attempting to use X.509 \ 
certificates with a signature algorithm of “x509v3-rsa2048-sha256”.
Fixed an issue with some links not working in the ReadTheDocs sidebar. Thanks go \ 
to Christoph Giese for reporting this issue.
Fixed keepalive handler to avoid leaking a timer object in some cases. Thanks go \ 
to Tom van Neerijnen for reporting this issue.
   2020-04-23 08:10:29 by Adam Ciarcinski | Files touched by this commit (2) | Package updated
Log message:
py-asyncssh: updated to 2.2.1

Release 2.2.1:

Added optional timeout parameter to SSHClientProcess.wait() and \ 
SSHClientConnection.run() methods.
Created subclasses for SFTPError exceptions, allowing applications to more \ 
easily have distinct exception handling for different errors.
Fixed an issue in SFTP parallel I/O related to handling low-level connection \ 
failures. Thanks go to Mikhail Terekhov for reporting this issue.
Fixed an issue with SFTP file copy where a local file could sometimes be left \ 
open if an attempt to close a remote file failed.
Fixed an issue in the handling of boolean return values when \ 
SSHServer.server_requested() returns a coroutine. Thanks go to Tom van Neerijnen \ 
for contributing this fix.
Fixed an issue with passing tuples to the SFTP copy functions. Thanks go to Marc \ 
Gagné for reporting this and doing the initial analysis.
   2020-03-12 17:36:31 by Adam Ciarcinski | Files touched by this commit (3) | Package updated
Log message:
py-asyncssh: updated to 2.2.0

Release 2.2.0

Added support for U2F/FIDO2 security keys, with the following capabilities:
ECDSA (NISTP256) and Ed25519 key algorithms
Key generation, including control over the application and user the key is \ 
associated with and whether touch is required when using the key
Certificate generation, both as a key being signed and a CA key
Resident keys, allowing security keys to be used on multiple machines without \ 
any information being stored outside of the key
Access to and management of keys loaded in an OpenSSH ssh-agent
Support for both user and host keys and certificates
Support for “no-touch-required” option in authorized_keys files
Support for “no-touch-required” option in OpenSSH certificates
Compatibility with security key support added in OpenSSH version 8.2
Added login timeout client option and limits on the length and number of banner \ 
lines AsyncSSH will accept prior to the SSH version header.
Improved load_keypairs() to read public key files, confirming that they are \ 
consistent with their associated private key when they are present.
Fixed issues in the SCP server related to handling filenames with spaces.
Fixed an issue with resuming reading after readuntil() returns an incomplete read.
Fixed a potential issue related to asyncio not reporting sockname/peername when \ 
a connection is closed immediately after it is opened.
Made SSHConnection a subclass of asyncio.Protocol to please type checkers.
   2019-12-01 12:45:35 by Adam Ciarcinski | Files touched by this commit (2) | Package updated
Log message:
py-asyncssh: updated to 2.1.0

Release 2.1.0:
Added support in the SSHProcess redirect mechanism to accept asyncio \ 
StreamReader and StreamWriter objects, allowing asyncio streams to be plugged in \ 
as stdin/stdout/stderr in an SSHProcess.
Added support for key handlers in the AsyncSSH line editor to trigger signals \ 
being delivered when certain “hot keys” are hit while reading input.
Improved cleanup of unreturned connection objects when an error occurs or the \ 
connection request is canceled or times out.
Improved cleanup of SSH agent client objects to avoid triggering a false \ 
positive warning in Python 3.8.
Added an example to the documentation for how to create reverse-direction SSH \ 
client and server connections.
Made check of session objects against None explicit to avoid confusion on \ 
user-defined sessions that implement __len__ or __bool__.

Release 2.0.1:
Some API changes which should have been included in the 2.0.0 release were \ 
missed. This release corrects that, but means that additional changes may be \ 
needed in applications moving to 2.0.1. This should hopefully be the last of \ 
such changes, but if any other issues are discovered, additional changes will be \ 
limited to 2.0.x patch releases and the API will stabilize again in the AsyncSSH \ 
2.1 release. See the next bullet for details about the additional incompatible \ 
To be consistent with other connect and listen functions, all methods on \ 
SSHClientConnection which previously returned None on listen failures have been \ 
changed to raise an exception instead. A new ChannelListenError exception will \ 
now be raised when an SSH server returns failure on a request to open a remote \ 
listener. This change affects the following SSHClientConnection methods: \ 
create_server, create_unix_server, start_server, start_unix_server, \ 
forward_remote_port, and forward_remote_path.
Restored the ability for SSHListener objects to be used as async context \ 
managers. This previously worked in AsyncSSH 1.x and was unintentionally broken \ 
in AsyncSSH 2.0.0.
Added support for a number of additional functions to be called from within an \ 
“async with” statement. These functions already returned objects capable of \ 
being async context managers, but were not decorated to allow them to be \ 
directly called from within “async with”. This change applies to the top \ 
level functions create_server, listen, and listen_reverse and the \ 
SSHClientConnection methods create_server, create_unix_server, start_server, \ 
start_unix_server, forward_local_port, forward_local_path, forward_remote_port, \ 
forward_remote_path, listen_ssh, and listen_reverse_ssh,
Fixed a couple of issues in loading OpenSSH-format certificates which were \ 
missing a trailing newline.
Changed load_certificates() to allow multiple certificates to be loaded from a \ 
single byte string argument, making it more consistent with how \ 
load_certificates() works when reading from a file.

Release 2.0.0:
NEW MAJOR VERSION: See below for potentially incompatible changes.
Updated AsyncSSH to use the modern async/await syntax internally, now requiring \ 
Python 3.6 or later. Those wishing to use AsyncSSH on Python 3.4 or 3.5 should \ 
stick to the AsyncSSH 1.x releases.
Changed first argument of SFTPServer constructor from an SSHServerConnection \ 
(conn) to an SSHServerChannel (chan) to allow custom SFTP server implementations \ 
to access environment variables set on the channel that SFTP is run over. \ 
Applications which subclass the SFTPServer class and implement an __init__ \ 
method will need to be updated to account for this change and pass the new \ 
argument through to the SFTPServer parent class. If the subclass has no __init__ \ 
and just uses the connection, channel, and env properties of SFTPServer to \ 
access this information, no changes should be required.
Removed deprecated “session_encoding” and “session_errors” arguments \ 
from create_server() and listen() functions. These arguments were renamed to \ 
“encoding” and “errors” back in version 1.16.0 to be consistent with \ 
other AsyncSSH APIs.
Removed get_environment(), get_command(), and get_subsystem() methods on \ 
SSHServerProcess class. This information was made available as “env”, \ 
“command”, and “subsystem” properties of SSHServerProcess in AsyncSSH \ 
Removed optional loop argument from all public AsyncSSH APIs, consistent with \ 
the deprecation of this argument in the asyncio package in Python 3.8. Calls \ 
will now always use the event loop which is active at the time of the call.
Removed support for non-async context managers on AsyncSSH connections and \ 
processes and SFTP client connections and file objects. Callers should use \ 
“async with” to invoke the async the context managers on these objects.
Added support for SSHAgentClient being an async context manager. To be \ 
consistent with other connect calls, connect_agent() will now raise an exception \ 
when no agent is found or a connection failure occurs, rather than logging a \ 
warning and returning None. Callers should catch OSError or ChannelOpenError \ 
exceptions rather than looking for a return value of None when calling this \ 
Added set_input() and clear_input() methods on SSHLineEditorChannel to change \ 
the value of the current input line when line editing is enabled.
Added is_closing() method to the SSHChannel, SSHProcess, SSHWriter, and \ 
SSHSubprocessTransport classes. mirroring the asyncio BaseTransport and \ 
StreamWriter methods added in Python 3.7.
Added wait_closed() async method to the SSHWriter class, mirroring the asyncio \ 
StreamWriter method added in Python 3.7.
   2019-08-25 14:24:06 by Adam Ciarcinski | Files touched by this commit (3) | Package updated
Log message:
py-asyncssh: updated to 1.18.0

Release 1.18.0:

Added support for GSSAPI ECDH and Edwards DH key exchange algorithms.
Fixed gssapi-with-mic authentication to work with GSS key exchanges, in cases \ 
where gssapi-keyex is not supported.
Made connect_ssh and connect_reverse_ssh methods into async context managers, \ 
simplifying the syntax needed to use them to create tunneled SSH connections.
Fixed a couple of issues with known hosts matching on tunneled SSH connections.
Improved flexibility of key/certificate parser automatic format detection to \ 
properly recognize PEM even when other arbitrary text is present at the \ 
beginning of the file. With this change, the parser can also now handle mixing \ 
of multiple key formats in a single file.
Added support for OpenSSL “TRUSTED” PEM certificates. For now, no \ 
enforcement is done of the additional trust restrictions, but such certificates \ 
can be loaded and used by AsyncSSH without converting them back to regular PEM \ 
Fixed some additional SFTP and SCP issues related to parsing of Windows paths \ 
with drive letters and paths with multiple colons.
Made AsyncSSH tolerant of a client which sends multiple service requests for the \ 
“ssh-userauth” service. This is needed by the Paramiko client when it tries \ 
more than one form of authentication on a connection.
   2019-08-03 13:43:47 by Adam Ciarcinski | Files touched by this commit (2) | Package updated
Log message:
py-asyncssh: updated to 1.17.1

Release 1.17.1:
Improved construction of file paths in SFTP to better handle native Windows \ 
source paths containing backslashes or drive letters.
Improved SFTP parallel I/O for large reads and file copies to better handle the \ 
case where a read returns less data than what was requested when not at the end \ 
of the file, allowing AsyncSSH to get back the right result even if the \ 
requested block size is larger than the SFTP server can handle.
Fixed an issue where the requested SFTP block_size wasn’t used in the get, \ 
copy, mget, and mcopy functions if it was larger than the default size of 16 KB.
Fixed a problem where the list of client keys provided in an \ 
SSHClientConnectionOptions object wasn’t always preserved properly across the \ 
opening of multiple SSH connections.
Changed SSH agent client code to avoid printing a warning on Windows when unable \ 
to connect to the SSH agent using the default path. A warning will be printed if \ 
the agent_path or SSH_AUTH_SOCK is explicitly set, but AsyncSSH will remain \ 
quiet if no agent path is set and no SSH agent is running.
Made AsyncSSH tolerant of unexpected authentication success/failure messages \ 
sent after authentication completes. AsyncSSH previously treated this as a \ 
protocol error and dropped the connection, while most other SSH implementations \ 
ignored these messages and allowed the connection to continue.
Made AsyncSSH tolerant of SFTP status responses which are missing error message \ 
and language tag fields, improving interoperability with servers that omit these \ 
fields. When missing, AsyncSSH treats these fields as if they were set to empty \ 
   2019-06-10 11:36:36 by Adam Ciarcinski | Files touched by this commit (2) | Package updated
Log message:
py-asyncssh: updated to 1.17.0

Release 1.17.0:
Added support for “reverse direction” SSH connections, useful to support \ 
applications like NETCONF Call Home, described in RFC 8071.
Added support for the PyCA implementation of Chacha20-Poly1305, eliminating the \ 
dependency on libnacl/libsodium to provide this functionality, as long as \ 
OpenSSL 1.1.1b or later is installed.
Restored libnacl support for Curve25519/Ed25519 on systems which have an older \ 
version of OpenSSL that doesn’t have that support. This fallback also applies \ 
to Chacha20-Poly1305.
Fixed Pageant support on Windows to use the Pageant agent by default when it is \ 
available and client keys are not explicitly configured.
Disabled the use of RSA SHA-2 signatures when using the Pageant or Windows 10 \ 
OpenSSH agent on Windows, since neither of those support the signature flags \ 
options to request them.
Fixed a regression where a callable was no longer usable in the sftp_factory \ 
argument of create_server.