From: Dr. Stephen Henson Date: Tue, 27 Feb 2007 18:42:52 +0000 (+0000) Subject: EVP_CIPHER_CTX_key_length() should return the set key length in the X-Git-Tag: FIPS_098_TEST_1~55^2~9 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=392a0345ded83e84771a339baae49bd6783a960c;p=openssl EVP_CIPHER_CTX_key_length() should return the set key length in the EVP_CIPHER_CTX structure which may not be the same as the underlying cipher key length for variable length ciphers. --- diff --git a/crypto/evp/evp_lib.c b/crypto/evp/evp_lib.c index f92db23af6..edb28ef38e 100644 --- a/crypto/evp/evp_lib.c +++ b/crypto/evp/evp_lib.c @@ -225,7 +225,7 @@ int EVP_CIPHER_key_length(const EVP_CIPHER *cipher) int EVP_CIPHER_CTX_key_length(const EVP_CIPHER_CTX *ctx) { - return ctx->cipher->key_len; + return ctx->key_len; } int EVP_CIPHER_nid(const EVP_CIPHER *cipher)