]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
wolfSSL: Implement tls_connection_get_own_cert_used()
authorJuliusz Sosinowicz <juliusz@wolfssl.com>
Thu, 26 Aug 2021 09:25:34 +0000 (11:25 +0200)
committerJouni Malinen <j@w1.fi>
Sun, 17 Apr 2022 19:02:28 +0000 (22:02 +0300)
This is needed for EAP-TEAP client implementation. This needs wolfSSL
5.0.0 or newer.

Signed-off-by: Juliusz Sosinowicz <juliusz@wolfssl.com>
src/crypto/tls_wolfssl.c

index e483b8027579ef8bd48f9f20742df31411d18213..56f5e4669017533bd7c015f657e268031210bdaf 100644 (file)
@@ -2146,3 +2146,11 @@ tls_connection_get_success_data(struct tls_connection *conn)
                return NULL;
        return wolfSSL_SESSION_get_ex_data(sess, tls_ex_idx_session);
 }
+
+
+bool tls_connection_get_own_cert_used(struct tls_connection *conn)
+{
+       if (conn)
+               return wolfSSL_get_certificate(conn->ssl) != NULL;
+       return false;
+}