From 740442bd8960b41466c152995617a70552bb8c1e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sosth=C3=A8ne=20Gu=C3=A9don?= Date: Fri, 22 Mar 2024 11:03:17 +0100 Subject: [PATCH] Fix compatibility with cryptography 42 --- pynitrokey/trussed/bootloader/lpc55_upload/crypto/keys.py | 2 +- pyproject.toml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pynitrokey/trussed/bootloader/lpc55_upload/crypto/keys.py b/pynitrokey/trussed/bootloader/lpc55_upload/crypto/keys.py index 06ab3dee..aa40bfc0 100644 --- a/pynitrokey/trussed/bootloader/lpc55_upload/crypto/keys.py +++ b/pynitrokey/trussed/bootloader/lpc55_upload/crypto/keys.py @@ -740,7 +740,7 @@ def _get_ec_curve_object(name: EccCurve) -> ec.EllipticCurve: for key_object in ec._CURVE_TYPES: if key_object.lower() == name.lower(): # pylint: disable=protected-access - return ec._CURVE_TYPES[key_object]() + return ec._CURVE_TYPES[key_object] raise SPSDKValueError(f"The EC curve with name '{name}' is not supported.") diff --git a/pyproject.toml b/pyproject.toml index c60d9910..0033eb9d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -24,7 +24,7 @@ dependencies = [ "certifi >= 14.5.14", "cffi", "click >=8.0, <=8.1.3", - "cryptography >=41.0.4,<44", + "cryptography >=42.0.4,<44", "ecdsa", "fido2 >=1.1.2,<2", "intelhex", @@ -32,7 +32,6 @@ dependencies = [ "python-dateutil ~= 2.7.0", "pyusb", "requests", - # "spsdk >=2.0,<2.2", "tqdm", "tlv8", "typing_extensions ~= 4.3.0", @@ -44,6 +43,7 @@ dependencies = [ "nethsm >= 1.0.0,<2", "asn1tools >= 0.166.0", "pyyaml >= 6.0.1", + "types-PyYAML>= 6.0.1", ] dynamic = ["version", "description"]