diff options
author | jsing <> | 2018-11-05 06:55:37 +0000 |
---|---|---|
committer | jsing <> | 2018-11-05 06:55:37 +0000 |
commit | 6947abc46581e19432245e0ce409d468fb702c7d (patch) | |
tree | 1b8aa8d5399aca7e65610168e61564f2acac553b /src/lib/libssl/t1_lib.c | |
parent | 2ab1af323eb2251dedee9fcb3661f284ae62b640 (diff) | |
download | openbsd-6947abc46581e19432245e0ce409d468fb702c7d.tar.gz openbsd-6947abc46581e19432245e0ce409d468fb702c7d.tar.bz2 openbsd-6947abc46581e19432245e0ce409d468fb702c7d.zip |
Clean up the code that checks if we can choose an EC cipher suite.
The tls1_check_ec_tmp_key() function is now rather misnamed, so just inline
the code. Also, rather than running tls1_get_shared_curve() once per EC
cipher suite, we can run it once at the start of the ssl3_choose_cipher()
function.
ok bluhm@ tb@
Diffstat (limited to 'src/lib/libssl/t1_lib.c')
-rw-r--r-- | src/lib/libssl/t1_lib.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/src/lib/libssl/t1_lib.c b/src/lib/libssl/t1_lib.c index 30305e6b2f..b06004e88a 100644 --- a/src/lib/libssl/t1_lib.c +++ b/src/lib/libssl/t1_lib.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: t1_lib.c,v 1.145 2018/11/05 03:49:44 jsing Exp $ */ | 1 | /* $OpenBSD: t1_lib.c,v 1.146 2018/11/05 06:55:37 jsing Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -604,17 +604,6 @@ tls1_check_ec_server_key(SSL *s) | |||
604 | return tls1_check_ec_key(s, &curve_id, &comp_id); | 604 | return tls1_check_ec_key(s, &curve_id, &comp_id); |
605 | } | 605 | } |
606 | 606 | ||
607 | /* Check EC temporary key is compatible with client extensions. */ | ||
608 | int | ||
609 | tls1_check_ec_tmp_key(SSL *s) | ||
610 | { | ||
611 | /* Need a shared curve. */ | ||
612 | if (tls1_get_shared_curve(s) != NID_undef) | ||
613 | return (1); | ||
614 | |||
615 | return (0); | ||
616 | } | ||
617 | |||
618 | /* | 607 | /* |
619 | * List of supported signature algorithms and hashes. Should make this | 608 | * List of supported signature algorithms and hashes. Should make this |
620 | * customisable at some point, for now include everything we support. | 609 | * customisable at some point, for now include everything we support. |