From d751fb9081e1ae2ff34b77e7a2a1d68c995faf73 Mon Sep 17 00:00:00 2001 From: Lee Miller Date: Sat, 16 Jul 2022 19:26:01 +0300 Subject: [PATCH] ctypes.c_size_t in argtypes of EVP_DigestUpdate and HMAC --- src/pyelliptic/openssl.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pyelliptic/openssl.py b/src/pyelliptic/openssl.py index ad14ca8a..ff6ff028 100644 --- a/src/pyelliptic/openssl.py +++ b/src/pyelliptic/openssl.py @@ -392,7 +392,7 @@ class _OpenSSL(object): self.EVP_DigestUpdate = self._lib.EVP_DigestUpdate self.EVP_DigestUpdate.restype = ctypes.c_int self.EVP_DigestUpdate.argtypes = [ctypes.c_void_p, - ctypes.c_void_p, ctypes.c_int] + ctypes.c_void_p, ctypes.c_size_t] self.EVP_DigestFinal = self._lib.EVP_DigestFinal self.EVP_DigestFinal.restype = ctypes.c_int @@ -472,7 +472,7 @@ class _OpenSSL(object): self.HMAC = self._lib.HMAC self.HMAC.restype = ctypes.c_void_p self.HMAC.argtypes = [ctypes.c_void_p, ctypes.c_void_p, ctypes.c_int, - ctypes.c_void_p, ctypes.c_int, + ctypes.c_void_p, ctypes.c_size_t, ctypes.c_void_p, ctypes.c_void_p] try: