summaryrefslogtreecommitdiff
path: root/thirdparty/openssl/crypto/evp/e_des3.c
diff options
context:
space:
mode:
Diffstat (limited to 'thirdparty/openssl/crypto/evp/e_des3.c')
-rw-r--r--thirdparty/openssl/crypto/evp/e_des3.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/thirdparty/openssl/crypto/evp/e_des3.c b/thirdparty/openssl/crypto/evp/e_des3.c
index 0e910d6d80..ab8126e5c9 100644
--- a/thirdparty/openssl/crypto/evp/e_des3.c
+++ b/thirdparty/openssl/crypto/evp/e_des3.c
@@ -212,6 +212,8 @@ static int des_ede3_cfb1_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
size_t n;
unsigned char c[1], d[1];
+ if (!EVP_CIPHER_CTX_test_flags(ctx, EVP_CIPH_FLAG_LENGTH_BITS))
+ inl *= 8;
for (n = 0; n < inl; ++n) {
c[0] = (in[n / 8] & (1 << (7 - n % 8))) ? 0x80 : 0;
DES_ede3_cfb_encrypt(c, d, 1, 1,