]> git.ipfire.org Git - thirdparty/openvpn.git/commit
Remove error injection into OpenSSL from cryptoapi.c
authorSelva Nair <selva.nair@gmail.com>
Tue, 19 Oct 2021 03:41:17 +0000 (23:41 -0400)
committerGert Doering <gert@greenie.muc.de>
Tue, 19 Oct 2021 15:26:36 +0000 (17:26 +0200)
commit6ad1fbce2bed1c5f8d2e29ab84f01b3939f8cca4
tree60f00d14db3132535d5b6e47cd9264c65e75ef1f
parent60c83cce885d2f89d0cc150b730b409538a59625
Remove error injection into OpenSSL from cryptoapi.c

There is no advantage in injecting/redirecting errors into OpenSSL
as we can, and we do, report these directly using our own logging
functions. This code probably originated from CAPI engine where
such usage made sense.

And, in cases when the error is within OpenSSL, guessing a
reason (like out of memory) and inserting it into the
OpenSSL error stack looks pointless.

As a bonus, the code gets leaner and a lot less cruft.

Some error messages are slightly edited and all near-fatal
errors are logged with M_NONFATAL and "Error in cryptoapicert:"
prefix.

Also remove some defines for mingw that we do not need.

Signed-off-by: Selva Nair <selva.nair@gmail.com>
Acked-by: Arne Schwabe <arne@rfc2549.org>
Message-Id: <20211019034118.28987-2-selva.nair@gmail.com>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg22951.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>
src/openvpn/cryptoapi.c