From: John Wolfe Date: Mon, 8 Nov 2021 21:33:58 +0000 (-0800) Subject: Update open-vm-tools 12.0.0 to work with openssl 1.1.1 or 3.0.0. X-Git-Tag: stable-12.0.0~72 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=04515ad7b6f3291af6236ef492de8bfb927d3151;p=thirdparty%2Fopen-vm-tools.git Update open-vm-tools 12.0.0 to work with openssl 1.1.1 or 3.0.0. --- diff --git a/open-vm-tools/vgauth/common/certverify.c b/open-vm-tools/vgauth/common/certverify.c index edf549287..9b268316d 100644 --- a/open-vm-tools/vgauth/common/certverify.c +++ b/open-vm-tools/vgauth/common/certverify.c @@ -93,11 +93,23 @@ VerifyDumpSSLErrors(void) const char *data; const char *file; unsigned long code; +#if OPENSSL_VERSION_NUMBER >= 0X30000000L + const char *func; +#endif +#if OPENSSL_VERSION_NUMBER >= 0X30000000L + code = ERR_get_error_all(&file, &line, &func, &data, &flags); +#else code = ERR_get_error_line_data(&file, &line, &data, &flags); +#endif while (code) { +#if OPENSSL_VERSION_NUMBER >= 0X30000000L + g_warning("SSL error: %lu (%s) in %s func %s line %d\n", + code, ERR_error_string(code, NULL), file, func, line); +#else g_warning("SSL error: %lu (%s) in %s line %d\n", code, ERR_error_string(code, NULL), file, line); +#endif if (data && (flags & ERR_TXT_STRING)) { g_warning("SSL error data: %s\n", data); } @@ -107,7 +119,11 @@ VerifyDumpSSLErrors(void) * until the SSL error buffer starts getting reused and a double * free happens. */ +#if OPENSSL_VERSION_NUMBER >= 0X30000000L + code = ERR_get_error_all(&file, &line, &func, &data, &flags); +#else code = ERR_get_error_line_data(&file, &line, &data, &flags); +#endif } }