diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2002-03-14 18:22:23 +0000 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2002-03-14 18:22:23 +0000 |
commit | de941e289e5d320d2e3258b0ebf71562830aaabc (patch) | |
tree | 082d81fe05a8c694a71a531dbe3eab7495773b17 /ssl | |
parent | 1d2845352926df66db5798cfebf3784f6af59b8c (diff) | |
download | openssl-de941e289e5d320d2e3258b0ebf71562830aaabc.tar.gz |
Initialize cipher context in KRB5
("D. Russell" <russelld@aol.net>)
Allow HMAC functions to use an alternative ENGINE.
Diffstat (limited to 'ssl')
-rw-r--r-- | ssl/s3_clnt.c | 2 | ||||
-rw-r--r-- | ssl/s3_srvr.c | 2 | ||||
-rw-r--r-- | ssl/t1_enc.c | 10 |
3 files changed, 9 insertions, 5 deletions
diff --git a/ssl/s3_clnt.c b/ssl/s3_clnt.c index 62571ef5d1..e5853ede95 100644 --- a/ssl/s3_clnt.c +++ b/ssl/s3_clnt.c @@ -1494,6 +1494,8 @@ static int ssl3_send_client_key_exchange(SSL *s) + EVP_MAX_IV_LENGTH]; int padl, outl = sizeof(epms); + EVP_CIPHER_CTX_init(&ciph_ctx); + #ifdef KSSL_DEBUG printf("ssl3_send_client_key_exchange(%lx & %lx)\n", l, SSL_kKRB5); diff --git a/ssl/s3_srvr.c b/ssl/s3_srvr.c index 61ed0ad10e..d6247a64ea 100644 --- a/ssl/s3_srvr.c +++ b/ssl/s3_srvr.c @@ -1557,6 +1557,8 @@ static int ssl3_get_client_key_exchange(SSL *s) krb5_timestamp authtime = 0; krb5_ticket_times ttimes; + EVP_CIPHER_CTX_init(&ciph_ctx); + if (!kssl_ctx) kssl_ctx = kssl_ctx_new(); n2s(p,i); diff --git a/ssl/t1_enc.c b/ssl/t1_enc.c index 0548533354..8b7844ceee 100644 --- a/ssl/t1_enc.c +++ b/ssl/t1_enc.c @@ -78,16 +78,16 @@ static void tls1_P_hash(const EVP_MD *md, const unsigned char *sec, HMAC_CTX_init(&ctx); HMAC_CTX_init(&ctx_tmp); - HMAC_Init_ex(&ctx,sec,sec_len,md); - HMAC_Init_ex(&ctx_tmp,sec,sec_len,md); + HMAC_Init_ex(&ctx,sec,sec_len,md, NULL); + HMAC_Init_ex(&ctx_tmp,sec,sec_len,md, NULL); HMAC_Update(&ctx,seed,seed_len); HMAC_Final(&ctx,A1,&A1_len); n=0; for (;;) { - HMAC_Init_ex(&ctx,NULL,0,NULL); /* re-init */ - HMAC_Init_ex(&ctx_tmp,NULL,0,NULL); /* re-init */ + HMAC_Init_ex(&ctx,NULL,0,NULL,NULL); /* re-init */ + HMAC_Init_ex(&ctx_tmp,NULL,0,NULL,NULL); /* re-init */ HMAC_Update(&ctx,A1,A1_len); HMAC_Update(&ctx_tmp,A1,A1_len); HMAC_Update(&ctx,seed,seed_len); @@ -652,7 +652,7 @@ int tls1_mac(SSL *ssl, unsigned char *md, int send) /* I should fix this up TLS TLS TLS TLS TLS XXXXXXXX */ HMAC_CTX_init(&hmac); - HMAC_Init_ex(&hmac,mac_sec,EVP_MD_size(hash),hash); + HMAC_Init_ex(&hmac,mac_sec,EVP_MD_size(hash),hash,NULL); HMAC_Update(&hmac,seq,8); HMAC_Update(&hmac,buf,5); HMAC_Update(&hmac,rec->input,rec->length); |