diff --git a/src/libcrypto.c b/src/libcrypto.c index e3b2f53c..393f5ed8 100644 --- a/src/libcrypto.c +++ b/src/libcrypto.c @@ -406,7 +406,7 @@ static void evp_cipher_init(struct ssh_cipher_struct *cipher) if (cipher->ctx == NULL) { cipher->ctx = EVP_CIPHER_CTX_new(); } else { - EVP_CIPHER_CTX_init(cipher->ctx); + EVP_CIPHER_CTX_reset(cipher->ctx); } switch(cipher->ciphertype){