X-Git-Url: https://git.openssl.org/gitweb/?a=blobdiff_plain;f=test%2Fhandshake_helper.h;h=604eed9bbac8f0ec24a326092f08bed1298e07c7;hb=2d60c923141e7853c268364f26195343a5e995bf;hp=d04655a9ed9da530eaca4590bd1607130f9b6472;hpb=5c753de668322bf9903a49ba713b2cbc62667571;p=openssl.git diff --git a/test/handshake_helper.h b/test/handshake_helper.h index d04655a9ed..604eed9bba 100644 --- a/test/handshake_helper.h +++ b/test/handshake_helper.h @@ -15,30 +15,53 @@ typedef struct handshake_result { ssl_test_result_t result; /* These alerts are in the 2-byte format returned by the info_callback. */ - /* Alert sent by the client; 0 if no alert. */ + /* (Latest) alert sent by the client; 0 if no alert. */ int client_alert_sent; - /* Alert received by the server; 0 if no alert. */ + /* Number of fatal or close_notify alerts sent. */ + int client_num_fatal_alerts_sent; + /* (Latest) alert received by the server; 0 if no alert. */ int client_alert_received; - /* Alert sent by the server; 0 if no alert. */ + /* (Latest) alert sent by the server; 0 if no alert. */ int server_alert_sent; - /* Alert received by the client; 0 if no alert. */ + /* Number of fatal or close_notify alerts sent. */ + int server_num_fatal_alerts_sent; + /* (Latest) alert received by the client; 0 if no alert. */ int server_alert_received; /* Negotiated protocol. On success, these should always match. */ int server_protocol; int client_protocol; /* Server connection */ - int servername; + ssl_servername_t servername; /* Session ticket status */ - int session_ticket; + 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; + /* Was the handshake resumed? */ + int client_resumed; + int server_resumed; + /* Temporary key type */ + int tmp_key_type; + /* server certificate key type */ + int server_cert_type; + /* server signing hash */ + int server_sign_hash; + /* client certificate key type */ + int client_cert_type; + /* client signing hash */ + int client_sign_hash; } HANDSHAKE_RESULT; -/* Do a handshake and report some information about the result. */ -HANDSHAKE_RESULT do_handshake(SSL_CTX *server_ctx, SSL_CTX *client_ctx, - const SSL_TEST_CTX *test_ctx); +HANDSHAKE_RESULT *HANDSHAKE_RESULT_new(void); +void HANDSHAKE_RESULT_free(HANDSHAKE_RESULT *result); -int do_not_call_session_ticket_callback(SSL* s, unsigned char* key_name, unsigned char *iv, - EVP_CIPHER_CTX *ctx, HMAC_CTX *hctx, int enc); +/* 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, SSL_CTX *resume_server_ctx, + SSL_CTX *resume_client_ctx, + const SSL_TEST_CTX *test_ctx); #endif /* HEADER_HANDSHAKE_HELPER_H */