Lines Matching refs:hs
261 struct tls13_secrets *secrets = ctx->hs->tls13.secrets; in tls13_phh_update_read_traffic_secret()
281 struct tls13_secrets *secrets = ctx->hs->tls13.secrets; in tls13_phh_update_write_traffic_secret()
376 struct tls13_secrets *secrets = ctx->hs->tls13.secrets; in tls13_new_session_ticket_recv()
544 ctx->hs = &ssl->s3->hs; in tls13_ctx_new()
664 if (ctx->hs->tls13.clienthello_md_ctx != NULL) in tls13_clienthello_hash_init()
666 if ((ctx->hs->tls13.clienthello_md_ctx = EVP_MD_CTX_new()) == NULL) in tls13_clienthello_hash_init()
668 if (!EVP_DigestInit_ex(ctx->hs->tls13.clienthello_md_ctx, in tls13_clienthello_hash_init()
672 if ((ctx->hs->tls13.clienthello_hash == NULL) && in tls13_clienthello_hash_init()
673 (ctx->hs->tls13.clienthello_hash = calloc(1, EVP_MAX_MD_SIZE)) == in tls13_clienthello_hash_init()
681 tls13_clienthello_hash_clear(struct ssl_handshake_tls13_st *hs) /* XXX */ in tls13_clienthello_hash_clear() argument
683 EVP_MD_CTX_free(hs->clienthello_md_ctx); in tls13_clienthello_hash_clear()
684 hs->clienthello_md_ctx = NULL; in tls13_clienthello_hash_clear()
685 freezero(hs->clienthello_hash, EVP_MAX_MD_SIZE); in tls13_clienthello_hash_clear()
686 hs->clienthello_hash = NULL; in tls13_clienthello_hash_clear()
693 return EVP_DigestUpdate(ctx->hs->tls13.clienthello_md_ctx, data, len); in tls13_clienthello_hash_update_bytes()
706 if (!EVP_DigestFinal_ex(ctx->hs->tls13.clienthello_md_ctx, in tls13_clienthello_hash_finalize()
707 ctx->hs->tls13.clienthello_hash, in tls13_clienthello_hash_finalize()
708 &ctx->hs->tls13.clienthello_hash_len)) in tls13_clienthello_hash_finalize()
710 EVP_MD_CTX_free(ctx->hs->tls13.clienthello_md_ctx); in tls13_clienthello_hash_finalize()
711 ctx->hs->tls13.clienthello_md_ctx = NULL; in tls13_clienthello_hash_finalize()
721 if (ctx->hs->tls13.clienthello_hash == NULL) in tls13_clienthello_hash_validate()
724 if (!EVP_DigestFinal_ex(ctx->hs->tls13.clienthello_md_ctx, in tls13_clienthello_hash_validate()
727 EVP_MD_CTX_free(ctx->hs->tls13.clienthello_md_ctx); in tls13_clienthello_hash_validate()
728 ctx->hs->tls13.clienthello_md_ctx = NULL; in tls13_clienthello_hash_validate()
730 if (ctx->hs->tls13.clienthello_hash_len != new_ch_hash_len) in tls13_clienthello_hash_validate()
732 if (memcmp(ctx->hs->tls13.clienthello_hash, new_ch_hash, in tls13_clienthello_hash_validate()