Skip to content

Commit 01ec4ba

Browse files
authored
Merge pull request #229 from asherf/fix
Fix deprecation warning from cryptography_backend.py
2 parents 29a3aaf + b899276 commit 01ec4ba

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

jose/backends/cryptography_backend.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
from cryptography.hazmat.primitives.keywrap import aes_key_wrap, aes_key_unwrap, InvalidUnwrap
2121
from cryptography.hazmat.primitives.padding import PKCS7
2222
from cryptography.hazmat.primitives.serialization import load_pem_private_key, load_pem_public_key
23-
from cryptography.utils import int_from_bytes, int_to_bytes
23+
from cryptography.utils import int_to_bytes
2424
from cryptography.x509 import load_pem_x509_certificate
2525

2626
_binding = None
@@ -145,8 +145,8 @@ def _raw_to_der(self, raw_signature):
145145

146146
r_bytes = raw_signature[:component_length]
147147
s_bytes = raw_signature[component_length:]
148-
r = int_from_bytes(r_bytes, "big")
149-
s = int_from_bytes(s_bytes, "big")
148+
r = int.from_bytes(r_bytes, "big")
149+
s = int.from_bytes(s_bytes, "big")
150150
return encode_dss_signature(r, s)
151151

152152
def sign(self, msg):

0 commit comments

Comments
 (0)