From ab623c923d4e2c950342aec5da371cb92b1fbbc6 Mon Sep 17 00:00:00 2001 From: mrezai Date: Tue, 3 May 2016 23:59:14 +0430 Subject: Update OpenSSL to 1.0.2h --- drivers/builtin_openssl2/crypto/pem/pem_lib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/builtin_openssl2/crypto/pem/pem_lib.c') diff --git a/drivers/builtin_openssl2/crypto/pem/pem_lib.c b/drivers/builtin_openssl2/crypto/pem/pem_lib.c index a29821aab2..fe881d6641 100644 --- a/drivers/builtin_openssl2/crypto/pem/pem_lib.c +++ b/drivers/builtin_openssl2/crypto/pem/pem_lib.c @@ -348,7 +348,7 @@ int PEM_ASN1_write_bio(i2d_of_void *i2d, const char *name, BIO *bp, if (enc != NULL) { objstr = OBJ_nid2sn(EVP_CIPHER_nid(enc)); - if (objstr == NULL) { + if (objstr == NULL || EVP_CIPHER_iv_length(enc) == 0) { PEMerr(PEM_F_PEM_ASN1_WRITE_BIO, PEM_R_UNSUPPORTED_CIPHER); goto err; } -- cgit v1.2.3