aboutsummaryrefslogtreecommitdiffstats
path: root/src/libstrongswan/plugins/openssl/openssl_util.c
diff options
context:
space:
mode:
authorTobias Brunner <tobias@strongswan.org>2016-04-08 15:54:08 +0200
committerTobias Brunner <tobias@strongswan.org>2016-04-15 10:32:52 +0200
commit77df573a9551c5a344ad00b901b1bbd47cd57134 (patch)
treebef41268f80b85a6e57e3e51d7f7b354779d46da /src/libstrongswan/plugins/openssl/openssl_util.c
parent9b85a6853b644d72a56319647ca2f45d456818b7 (diff)
downloadstrongswan-77df573a9551c5a344ad00b901b1bbd47cd57134.tar.bz2
strongswan-77df573a9551c5a344ad00b901b1bbd47cd57134.tar.xz
openssl: Use proper EVP macro to determine size of a hash
Diffstat (limited to 'src/libstrongswan/plugins/openssl/openssl_util.c')
-rw-r--r--src/libstrongswan/plugins/openssl/openssl_util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstrongswan/plugins/openssl/openssl_util.c b/src/libstrongswan/plugins/openssl/openssl_util.c
index 2f9813701..914060358 100644
--- a/src/libstrongswan/plugins/openssl/openssl_util.c
+++ b/src/libstrongswan/plugins/openssl/openssl_util.c
@@ -51,7 +51,7 @@ bool openssl_hash_chunk(int hash_type, chunk_t data, chunk_t *hash)
goto error;
}
- *hash = chunk_alloc(hasher->md_size);
+ *hash = chunk_alloc(EVP_MD_size(hasher));
if (!EVP_DigestFinal_ex(ctx, hash->ptr, NULL))
{
chunk_free(hash);