summaryrefslogtreecommitdiff
path: root/testcode/streamtcp.c
diff options
context:
space:
mode:
authorCy Schubert <cy@FreeBSD.org>2024-08-16 16:41:16 +0000
committerCy Schubert <cy@FreeBSD.org>2024-08-16 16:41:16 +0000
commit96ef46e5cff01648c80c09c4364d10bc6f58119d (patch)
treea759010619ad11a8eaaaed7269bb06a9dfc2fa16 /testcode/streamtcp.c
parentc2a80056864d6eda0398fd127dc0ae515b39752b (diff)
Diffstat (limited to 'testcode/streamtcp.c')
-rw-r--r--testcode/streamtcp.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/testcode/streamtcp.c b/testcode/streamtcp.c
index 037bcfd8b6a4..60122c4ddfd1 100644
--- a/testcode/streamtcp.c
+++ b/testcode/streamtcp.c
@@ -471,7 +471,11 @@ send_em(const char* svr, const char* pp2_client, int udp, int usessl,
}
}
if(1) {
+#ifdef HAVE_SSL_GET1_PEER_CERTIFICATE
+ X509* x = SSL_get1_peer_certificate(ssl);
+#else
X509* x = SSL_get_peer_certificate(ssl);
+#endif
if(!x) printf("SSL: no peer certificate\n");
else {
X509_print_fp(stdout, x);