diff options
author | 2020-02-04 18:00:30 +0000 | |
---|---|---|
committer | 2020-02-04 18:00:30 +0000 | |
commit | daaa2dc51eb27a65687d63edfed7cb6374475a85 (patch) | |
tree | 56a9eea9cd63703b531fb9140b6e9fb4a265c1fc /lib/libssl/tls13_client.c | |
parent | Remove unused files. (diff) | |
download | wireguard-openbsd-daaa2dc51eb27a65687d63edfed7cb6374475a85.tar.xz wireguard-openbsd-daaa2dc51eb27a65687d63edfed7cb6374475a85.zip |
Free the transcript as soon as we initialise the transcript hash.
Unlike TLSv1.2 there is only a single hash in use, hence as soon as we
know what the hash is and have initialised the transcript hash, we can
free the transcript buffers.
ok inoguchi@ tb@
Diffstat (limited to 'lib/libssl/tls13_client.c')
-rw-r--r-- | lib/libssl/tls13_client.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/libssl/tls13_client.c b/lib/libssl/tls13_client.c index 69e75558dc1..78f46bd8592 100644 --- a/lib/libssl/tls13_client.c +++ b/lib/libssl/tls13_client.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tls13_client.c,v 1.39 2020/01/30 17:09:23 jsing Exp $ */ +/* $OpenBSD: tls13_client.c,v 1.40 2020/02/04 18:00:30 jsing Exp $ */ /* * Copyright (c) 2018, 2019 Joel Sing <jsing@openbsd.org> * @@ -435,6 +435,7 @@ tls13_server_hello_recv(struct tls13_ctx *ctx, CBS *cbs) /* XXX - pass in hash. */ if (!tls1_transcript_hash_init(s)) goto err; + tls1_transcript_free(s); if (!tls1_transcript_hash_value(s, buf, sizeof(buf), &hash_len)) goto err; context.data = buf; |