2019-06-16 21:59:06 +02:00
|
|
|
{ stdenv, buildPythonPackage, fetchPypi, pythonOlder
|
2018-05-23 00:09:33 +02:00
|
|
|
, cryptography
|
2018-09-16 10:48:14 +02:00
|
|
|
, bcrypt, gssapi, libnacl, libsodium, nettle, pyopenssl
|
2019-03-30 18:28:27 +01:00
|
|
|
, openssl, openssh }:
|
2018-05-23 00:09:33 +02:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "asyncssh";
|
2019-12-19 20:31:04 +01:00
|
|
|
version = "2.1.0";
|
2018-05-23 00:09:33 +02:00
|
|
|
disabled = pythonOlder "3.4";
|
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2019-12-19 20:31:04 +01:00
|
|
|
sha256 = "19d0b4c65115d09b42ed21c748884157babfb3055a6e130ea349dfdcbcef3380";
|
2018-05-23 00:09:33 +02:00
|
|
|
};
|
|
|
|
|
2019-03-30 18:28:27 +01:00
|
|
|
patches = [
|
|
|
|
# Reverts https://github.com/ronf/asyncssh/commit/4b3dec994b3aa821dba4db507030b569c3a32730
|
|
|
|
#
|
|
|
|
# This changed the test to avoid setting the sticky bit
|
|
|
|
# because that's not allowed for plain files in FreeBSD.
|
|
|
|
# However that broke the test on NixOS, failing with
|
|
|
|
# "Operation not permitted"
|
|
|
|
./fix-sftp-chmod-test-nixos.patch
|
|
|
|
];
|
|
|
|
|
2018-09-16 10:48:14 +02:00
|
|
|
propagatedBuildInputs = [
|
2018-05-23 00:09:33 +02:00
|
|
|
bcrypt
|
|
|
|
cryptography
|
|
|
|
gssapi
|
|
|
|
libnacl
|
|
|
|
libsodium
|
|
|
|
nettle
|
|
|
|
pyopenssl
|
|
|
|
];
|
|
|
|
|
2019-03-30 18:28:27 +01:00
|
|
|
checkInputs = [
|
|
|
|
openssh
|
|
|
|
openssl
|
|
|
|
];
|
2018-09-16 10:48:14 +02:00
|
|
|
|
2018-05-23 00:09:33 +02:00
|
|
|
# Disables windows specific test (specifically the GSSAPI wrapper for Windows)
|
|
|
|
postPatch = ''
|
2019-03-30 18:28:27 +01:00
|
|
|
rm tests/sspi_stub.py
|
2018-05-23 00:09:33 +02:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Provides an asynchronous client and server implementation of the SSHv2 protocol on top of the Python asyncio framework";
|
2019-03-30 18:28:27 +01:00
|
|
|
homepage = https://asyncssh.readthedocs.io/en/latest;
|
|
|
|
license = licenses.epl20;
|
2018-05-23 00:09:33 +02:00
|
|
|
maintainers = with maintainers; [ worldofpeace ];
|
|
|
|
};
|
|
|
|
}
|