Actually set the tlscert conn reference

Previously it was always NULL
This commit is contained in:
Stephen Paul Weber
2025-07-08 15:33:29 -05:00
committed by Steffen Jaeckel
parent 649a3b4fca
commit f8cda0f65c
2 changed files with 4 additions and 0 deletions

View File

@@ -422,6 +422,8 @@ static int _tls_verify(gnutls_session_t session)
return -1;
}
tlscert->conn = tls->conn;
if (tls->conn->certfail_handler(tlscert, (char *)out.data) == 0) {
xmpp_tlscert_free(tlscert);
gnutls_x509_crt_deinit(cert);

View File

@@ -540,6 +540,8 @@ static int _tls_verify(int preverify_ok, X509_STORE_CTX *x509_ctx)
if (!tlscert)
return 0;
tlscert->conn = conn;
strophe_debug(conn->ctx, "tls", "preverify_ok:%d\nSubject: %s\nIssuer: %s",
preverify_ok, tlscert->elements[XMPP_CERT_SUBJECT],
tlscert->elements[XMPP_CERT_ISSUER]);