mirror of
https://github.com/postgres/postgres.git
synced 2025-06-25 01:02:05 +03:00
Fix build with older OpenSSL versions
Apparently, X509_get_signature_nid() is only in fairly new OpenSSL versions, so use the lower-level interface it is built on instead.
This commit is contained in:
@ -447,7 +447,7 @@ pgtls_get_peer_certificate_hash(PGconn *conn, size_t *len)
|
||||
* Get the signature algorithm of the certificate to determine the hash
|
||||
* algorithm to use for the result.
|
||||
*/
|
||||
if (!OBJ_find_sigid_algs(X509_get_signature_nid(peer_cert),
|
||||
if (!OBJ_find_sigid_algs(OBJ_obj2nid(peer_cert->sig_alg->algorithm),
|
||||
&algo_nid, NULL))
|
||||
{
|
||||
printfPQExpBuffer(&conn->errorMessage,
|
||||
|
Reference in New Issue
Block a user