summaryrefslogtreecommitdiff
path: root/src/regress/lib
diff options
context:
space:
mode:
authorjsing <>2020-02-05 18:06:42 +0000
committerjsing <>2020-02-05 18:06:42 +0000
commiteb4895a6c4e6a61a07bc7525508c056ceca15fcf (patch)
treebcb1a81555c46a1ba4195fad9f0c46b235497d24 /src/regress/lib
parentb4766dc0b43a58fb924f86b32ea9dc519e138f45 (diff)
downloadopenbsd-eb4895a6c4e6a61a07bc7525508c056ceca15fcf.tar.gz
openbsd-eb4895a6c4e6a61a07bc7525508c056ceca15fcf.tar.bz2
openbsd-eb4895a6c4e6a61a07bc7525508c056ceca15fcf.zip
Reset the key share so that we do not have an existing peer public key.
Diffstat (limited to 'src/regress/lib')
-rw-r--r--src/regress/lib/libssl/tlsext/tlsexttest.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/regress/lib/libssl/tlsext/tlsexttest.c b/src/regress/lib/libssl/tlsext/tlsexttest.c
index 6c7e9a06cb..c15724da29 100644
--- a/src/regress/lib/libssl/tlsext/tlsexttest.c
+++ b/src/regress/lib/libssl/tlsext/tlsexttest.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: tlsexttest.c,v 1.33 2020/02/01 12:42:39 jsing Exp $ */ 1/* $OpenBSD: tlsexttest.c,v 1.34 2020/02/05 18:06:42 jsing Exp $ */
2/* 2/*
3 * Copyright (c) 2017 Joel Sing <jsing@openbsd.org> 3 * Copyright (c) 2017 Joel Sing <jsing@openbsd.org>
4 * Copyright (c) 2017 Doug Hogan <doug@openbsd.org> 4 * Copyright (c) 2017 Doug Hogan <doug@openbsd.org>
@@ -3297,6 +3297,12 @@ test_tlsext_keyshare_server(void)
3297 goto done; 3297 goto done;
3298 } 3298 }
3299 3299
3300 if ((S3I(ssl)->hs_tls13.key_share =
3301 tls13_key_share_new(NID_X25519)) == NULL)
3302 errx(1, "failed to create key share");
3303 if (!tls13_key_share_generate(S3I(ssl)->hs_tls13.key_share))
3304 errx(1, "failed to generate key share");
3305
3300 CBS_init(&cbs, data, dlen); 3306 CBS_init(&cbs, data, dlen);
3301 3307
3302 if (!tlsext_keyshare_client_parse(ssl, &cbs, &alert)) { 3308 if (!tlsext_keyshare_client_parse(ssl, &cbs, &alert)) {