SSL test framework: port NPN and ALPN tests
[oweals/openssl.git] / test / handshake_helper.h
index 4a51ad4a6ecf2820c70be29ce9767301ea8372de..56c0aac28a01369983c2e7421560c1676939834d 100644 (file)
@@ -32,10 +32,17 @@ typedef struct handshake_result {
     ssl_session_ticket_t session_ticket;
     /* Was this called on the second context? */
     int session_ticket_do_not_call;
+    char *client_npn_negotiated;
+    char *server_npn_negotiated;
+    char *client_alpn_negotiated;
+    char *server_alpn_negotiated;
 } HANDSHAKE_RESULT;
 
+HANDSHAKE_RESULT *HANDSHAKE_RESULT_new(void);
+void HANDSHAKE_RESULT_free(HANDSHAKE_RESULT *result);
+
 /* Do a handshake and report some information about the result. */
-HANDSHAKE_RESULT do_handshake(SSL_CTX *server_ctx, SSL_CTX *server2_ctx,
-                              SSL_CTX *client_ctx, const SSL_TEST_CTX *test_ctx);
+HANDSHAKE_RESULT *do_handshake(SSL_CTX *server_ctx, SSL_CTX *server2_ctx,
+                               SSL_CTX *client_ctx, const SSL_TEST_CTX *test_ctx);
 
 #endif  /* HEADER_HANDSHAKE_HELPER_H */