diff options
author | Richard Levitte <levitte@openssl.org> | 2016-06-14 00:44:29 +0200 |
---|---|---|
committer | Richard Levitte <levitte@openssl.org> | 2016-06-14 00:44:29 +0200 |
commit | a8c82fa00f18ef0e2115864af640e6098c136793 (patch) | |
tree | b8f46120d12132dd19852f2a4642ab58b6d67c77 /test | |
parent | 35096e912c4eba6c5ffd961d36fc92f1ddf34240 (diff) |
Shorten some symbol names
VMS C doesn't allow symbols longer than 31 characters. We do the
automatic shortening with the library files, but not otherwise (to
make sure to work the VMS C magic).
For consistency, I shortened other similar symbols in the same manner.
Reviewed-by: Rich Salz <rsalz@openssl.org>
Diffstat (limited to 'test')
-rw-r--r-- | test/handshake_helper.c | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/test/handshake_helper.c b/test/handshake_helper.c index 22ba1ce0f9..a60c9c6845 100644 --- a/test/handshake_helper.c +++ b/test/handshake_helper.c @@ -28,7 +28,7 @@ typedef struct handshake_ex_data { static int ex_data_idx; -static void info_callback(const SSL *s, int where, int ret) +static void info_cb(const SSL *s, int where, int ret) { if (where & SSL_CB_ALERT) { HANDSHAKE_EX_DATA *ex_data = @@ -41,7 +41,7 @@ static void info_callback(const SSL *s, int where, int ret) } } -static int servername_callback(SSL *s, int *ad, void *arg) +static int servername_cb(SSL *s, int *ad, void *arg) { const char *servername = SSL_get_servername(s, TLSEXT_NAMETYPE_host_name); if (servername != NULL && !strcmp(servername, "server2")) { @@ -58,25 +58,25 @@ static int servername_callback(SSL *s, int *ad, void *arg) return SSL_TLSEXT_ERR_OK; } -static int verify_reject_callback(X509_STORE_CTX *ctx, void *arg) { +static int verify_reject_cb(X509_STORE_CTX *ctx, void *arg) { X509_STORE_CTX_set_error(ctx, X509_V_ERR_APPLICATION_VERIFICATION); return 0; } -static int verify_accept_callback(X509_STORE_CTX *ctx, void *arg) { +static int verify_accept_cb(X509_STORE_CTX *ctx, void *arg) { return 1; } -static int broken_session_ticket_callback(SSL* s, unsigned char* key_name, unsigned char *iv, - EVP_CIPHER_CTX *ctx, HMAC_CTX *hctx, int enc) +static int broken_session_ticket_cb(SSL* s, unsigned char* key_name, unsigned char *iv, + EVP_CIPHER_CTX *ctx, HMAC_CTX *hctx, int enc) { return 0; } -static 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) +static int do_not_call_session_ticket_cb(SSL* s, unsigned char* key_name, + unsigned char *iv, + EVP_CIPHER_CTX *ctx, + HMAC_CTX *hctx, int enc) { HANDSHAKE_EX_DATA *ex_data = (HANDSHAKE_EX_DATA*)(SSL_get_ex_data(s, ex_data_idx)); @@ -94,11 +94,11 @@ static void configure_handshake_ctx(SSL_CTX *server_ctx, SSL_CTX *server2_ctx, { switch (test_ctx->client_verify_callback) { case SSL_TEST_VERIFY_ACCEPT_ALL: - SSL_CTX_set_cert_verify_callback(client_ctx, &verify_accept_callback, + SSL_CTX_set_cert_verify_callback(client_ctx, &verify_accept_cb, NULL); break; case SSL_TEST_VERIFY_REJECT_ALL: - SSL_CTX_set_cert_verify_callback(client_ctx, &verify_reject_callback, + SSL_CTX_set_cert_verify_callback(client_ctx, &verify_reject_cb, NULL); break; default: @@ -106,17 +106,17 @@ static void configure_handshake_ctx(SSL_CTX *server_ctx, SSL_CTX *server2_ctx, } /* link the two contexts for SNI purposes */ - SSL_CTX_set_tlsext_servername_callback(server_ctx, servername_callback); + SSL_CTX_set_tlsext_servername_callback(server_ctx, servername_cb); SSL_CTX_set_tlsext_servername_arg(server_ctx, server2_ctx); /* * The initial_ctx/session_ctx always handles the encrypt/decrypt of the * session ticket. This ticket_key callback is assigned to the second * session (assigned via SNI), and should never be invoked */ - SSL_CTX_set_tlsext_ticket_key_cb(server2_ctx, do_not_call_session_ticket_callback); + SSL_CTX_set_tlsext_ticket_key_cb(server2_ctx, do_not_call_session_ticket_cb); if (test_ctx->session_ticket_expected == SSL_TEST_SESSION_TICKET_BROKEN) { - SSL_CTX_set_tlsext_ticket_key_cb(server_ctx, broken_session_ticket_callback); + SSL_CTX_set_tlsext_ticket_key_cb(server_ctx, broken_session_ticket_cb); } } @@ -285,8 +285,8 @@ HANDSHAKE_RESULT do_handshake(SSL_CTX *server_ctx, SSL_CTX *server2_ctx, OPENSSL_assert(SSL_set_ex_data(client, ex_data_idx, &client_ex_data) == 1); - SSL_set_info_callback(server, &info_callback); - SSL_set_info_callback(client, &info_callback); + SSL_set_info_callback(server, &info_cb); + SSL_set_info_callback(client, &info_cb); /* * Half-duplex handshake loop. |