From ebc6f63d8f25c480b8935860c595154df01bee3e Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Tue, 4 Nov 2025 01:13:49 +0000 Subject: Avoid using deprecated functions in ssl_openssl. --- modules/extra/ssl_openssl.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'modules/extra/ssl_openssl.cpp') diff --git a/modules/extra/ssl_openssl.cpp b/modules/extra/ssl_openssl.cpp index 38141cce8..921f2576a 100644 --- a/modules/extra/ssl_openssl.cpp +++ b/modules/extra/ssl_openssl.cpp @@ -45,6 +45,9 @@ #include "timeutils.h" #include "utility/string.h" +#define OPENSSL_API_COMPAT 30000 +#define OPENSSL_NO_DEPRECATED + #include #include #include @@ -548,7 +551,7 @@ private: auto* certinfo = new ssl_cert(); this->certificate = certinfo; - auto* cert = SSL_get_peer_certificate(sess); + auto* cert = SSL_get1_peer_certificate(sess); if (!cert) { certinfo->error = "Could not get peer certificate: "+std::string(get_error()); -- cgit v1.3.1-10-gc9f91