]> git.ipfire.org Git - thirdparty/openvpn.git/commit
OpenSSL: use EVP_CipherInit_ex() instead of EVP_CipherInit()
authorEmmanuel Deloget <logout@free.fr>
Mon, 20 Feb 2017 14:32:34 +0000 (15:32 +0100)
committerGert Doering <gert@greenie.muc.de>
Sun, 5 Mar 2017 11:23:17 +0000 (12:23 +0100)
commit8d00afae88b626c9cf14170a943b33a7ed378070
tree28f819fb098b9a2f29b2cf6a08bb852d493ed1ec
parentc828ffc648eebda20e2f9087248944fa0f52a582
OpenSSL: use EVP_CipherInit_ex() instead of EVP_CipherInit()

The behavior of EVP_CipherInit() changed in OpenSSL 1.1 -- instead
of clearing the context when the cipher parameter was !NULL, it now
clears the context unconditionnaly. As a result, subsequent calls
to the function with additional information now fails.

The bulk work is done by EVP_CipherInit_ex() which has been part of the
OpenSSL interface since the dawn of time (0.9.8 already has it). Thus,
the change allows us to get the old behavior back instead of relying
on dirty tricks.

Signed-off-by: Emmanuel Deloget <logout@free.fr>
Acked-by: Steffan Karger <steffan.karger@fox-it.com>
Message-Id: <2faff7647151d7fe362c1c5db9f97e520444d09b.1487600539.git.logout@free.fr>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg14120.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>
src/openvpn/crypto_openssl.c