diff options
author | Theo Buehler <tb@cvs.openbsd.org> | 2022-07-02 16:00:13 +0000 |
---|---|---|
committer | Theo Buehler <tb@cvs.openbsd.org> | 2022-07-02 16:00:13 +0000 |
commit | 1b9b5ed09cc7b8b3f804984b896336aa5ba1e666 (patch) | |
tree | 772441c51309264d8e5901bfe9839f1382e2938d /lib/libssl/tls13_server.c | |
parent | 4db0108a7d8704bed44f931f7cd25688a65fa57c (diff) |
Rename uses 'curve' to 'group' and rework tls1 group API.
This reworks various tls1_ curve APIs to indicate success via a boolean
return value and move the output to an out parameter. This makes the
caller code easier and more consistent.
Based on a suggestion by jsing
ok jsing
Diffstat (limited to 'lib/libssl/tls13_server.c')
-rw-r--r-- | lib/libssl/tls13_server.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libssl/tls13_server.c b/lib/libssl/tls13_server.c index 2c1c12ff258..c5c86ab95f5 100644 --- a/lib/libssl/tls13_server.c +++ b/lib/libssl/tls13_server.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tls13_server.c,v 1.98 2022/06/04 01:14:43 tb Exp $ */ +/* $OpenBSD: tls13_server.c,v 1.99 2022/07/02 16:00:12 tb Exp $ */ /* * Copyright (c) 2019, 2020 Joel Sing <jsing@openbsd.org> * Copyright (c) 2020 Bob Beck <beck@openbsd.org> @@ -432,9 +432,9 @@ tls13_server_hello_retry_request_send(struct tls13_ctx *ctx, CBB *cbb) if (ctx->hs->key_share != NULL) return 0; - if ((nid = tls1_get_shared_curve(ctx->ssl)) == NID_undef) + if (!tls1_get_supported_group(ctx->ssl, &nid)) return 0; - if ((ctx->hs->tls13.server_group = tls1_ec_nid2curve_id(nid)) == 0) + if (!tls1_ec_nid2group_id(nid, &ctx->hs->tls13.server_group)) return 0; if (!tls13_server_hello_build(ctx, cbb, 1)) |