2020-11-12 23:50:31 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, gmp
|
|
|
|
, pytestCheckHook
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "fastecdsa";
|
2021-12-06 16:07:01 +00:00
|
|
|
version = "2.2.2";
|
|
|
|
format = "setuptools";
|
2020-11-12 23:50:31 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2021-12-06 16:07:01 +00:00
|
|
|
sha256 = "1eb6f3ac86ec483a10df62fcda1fb9a9d5d895a436871a8aa935dd20ccd82c6f";
|
2020-11-12 23:50:31 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ gmp ];
|
|
|
|
|
|
|
|
checkInputs = [ pytestCheckHook ];
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
disabledTestPaths = [
|
|
|
|
# skip tests which require being online to download test vectors
|
|
|
|
"fastecdsa/tests/test_wycheproof_vectors.py"
|
|
|
|
"fastecdsa/tests/test_rfc6979_ecdsa.py"
|
2020-11-12 23:50:31 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
# skip tests for now, they fail with
|
|
|
|
# ImportError: cannot import name '_ecdsa' from 'fastecdsa'
|
|
|
|
# but the installed package works just fine
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "fastecdsa" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Fast elliptic curve digital signatures";
|
|
|
|
homepage = "https://github.com/AntonKueltz/fastecdsa";
|
|
|
|
license = licenses.unlicense;
|
|
|
|
maintainers = with maintainers; [ prusnak ];
|
|
|
|
};
|
|
|
|
}
|