2021-07-14 22:03:04 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, pythonOlder
|
2020-04-24 23:36:52 +00:00
|
|
|
, cryptography
|
2021-07-14 22:03:04 +00:00
|
|
|
, bcrypt
|
|
|
|
, gssapi
|
|
|
|
, fido2
|
|
|
|
, libnacl
|
|
|
|
, libsodium
|
|
|
|
, nettle
|
|
|
|
, python-pkcs11
|
|
|
|
, pyopenssl
|
|
|
|
, openssl
|
|
|
|
, openssh
|
|
|
|
, pytestCheckHook
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "asyncssh";
|
2021-07-14 22:03:04 +00:00
|
|
|
version = "2.7.0";
|
|
|
|
disabled = pythonOlder "3.6";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2021-07-14 22:03:04 +00:00
|
|
|
sha256 = "sha256-GFAT2OZ3R8PA8BtyQWuL14QX2h30jHH3baU8YH71QbY=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
bcrypt
|
|
|
|
cryptography
|
2021-07-14 22:03:04 +00:00
|
|
|
fido2
|
2020-04-24 23:36:52 +00:00
|
|
|
gssapi
|
|
|
|
libnacl
|
|
|
|
libsodium
|
|
|
|
nettle
|
2021-07-14 22:03:04 +00:00
|
|
|
python-pkcs11
|
2020-04-24 23:36:52 +00:00
|
|
|
pyopenssl
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
openssh
|
|
|
|
openssl
|
2020-11-24 20:58:05 +00:00
|
|
|
pytestCheckHook
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2021-07-14 22:03:04 +00: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
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTestPaths = [
|
|
|
|
# Disables windows specific test (specifically the GSSAPI wrapper for Windows)
|
|
|
|
"tests/sspi_stub.py"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "asyncssh" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2021-07-14 22:03:04 +00:00
|
|
|
description = "Asynchronous SSHv2 Python client and server library";
|
|
|
|
homepage = "https://asyncssh.readthedocs.io/";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.epl20;
|
2021-05-20 23:08:51 +00:00
|
|
|
maintainers = with maintainers; [ ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|