auditdistd: Avoid deprecated OpenSSL APIs

SSL_use_RSAPrivateKey_file() was deprecated in OpenSSL 3.0.  Use the
more generic SSL_use_PrivateKey_file() instead.

Sponsored by:	Klara, Inc.
Sponsored by:	Qualys, Inc.
Reviewed by:	emaste
Differential Revision:	https://reviews.freebsd.org/D60899
This commit is contained in:
Dag-Erling Smørgrav committed 2026-10-22 17:13:47 +02:00
1 parent c7523e8cfb
commit 8133230d7e
1 file changed
+2 -2
+2 -2
View File
@@ -679,10 +679,10 @@ tls_exec_server(const char *user, int startfd, const char *privkey,
if (ssl == NULL)
pjdlog_exitx(EX_TEMPFAIL, "SSL_new() failed.");
if (SSL_use_RSAPrivateKey_file(ssl, privkey, SSL_FILETYPE_PEM) != 1) {
if (SSL_use_PrivateKey_file(ssl, privkey, SSL_FILETYPE_PEM) != 1) {
ssl_log_errors();
pjdlog_exitx(EX_CONFIG,
"SSL_use_RSAPrivateKey_file(%s) failed.", privkey);
"SSL_use_PrivateKey_file(%s) failed.", privkey);
}
if (SSL_use_certificate_file(ssl, cert, SSL_FILETYPE_PEM) != 1) {