1{ lib
2, buildPythonPackage
3, cryptography
4, fetchPypi
5, mock
6, poetry-core
7, pyfakefs
8, pythonOlder
9, six
10, unittestCheckHook
11}:
12
13buildPythonPackage rec {
14 pname = "fido2";
15 version = "1.1.2";
16 format = "pyproject";
17
18 disabled = pythonOlder "3.7";
19
20 src = fetchPypi {
21 inherit pname version;
22 hash = "sha256-YRDZExBvdhmSAbMtJisoV1YsxGuh0LnFH7zjDck2xXM=";
23 };
24
25 nativeBuildInputs = [
26 poetry-core
27 ];
28
29 propagatedBuildInputs = [
30 cryptography
31 six
32 ];
33
34 nativeCheckInputs = [
35 unittestCheckHook
36 mock
37 pyfakefs
38 ];
39
40 unittestFlagsArray = [
41 "-v"
42 ];
43
44 pythonImportsCheck = [
45 "fido2"
46 ];
47
48 meta = with lib; {
49 description = "Provides library functionality for FIDO 2.0, including communication with a device over USB";
50 homepage = "https://github.com/Yubico/python-fido2";
51 changelog = "https://github.com/Yubico/python-fido2/releases/tag/${version}";
52 license = licenses.bsd2;
53 maintainers = with maintainers; [ prusnak ];
54 };
55}