From 14041d8f93fcd895cc979e82e817751df51ac1f3 Mon Sep 17 00:00:00 2001 From: Dmitry Eremin-Solenikov Date: Mon, 24 Jun 2019 01:37:31 +0300 Subject: ext/supported_groups: don't consider non-EC groups for EC Signed-off-by: Dmitry Eremin-Solenikov --- lib/ext/supported_groups.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/ext/supported_groups.c b/lib/ext/supported_groups.c index ef7859f731..ab704d41e5 100644 --- a/lib/ext/supported_groups.c +++ b/lib/ext/supported_groups.c @@ -159,7 +159,7 @@ _gnutls_supported_groups_recv_params(gnutls_session_t session, break; serv_dh_idx = j; cli_dh_pos = i; - } else { + } else if (IS_EC(group->pk)) { if (serv_ec_idx != -1 && (int)j > serv_ec_idx) break; serv_ec_idx = j; @@ -171,7 +171,7 @@ _gnutls_supported_groups_recv_params(gnutls_session_t session, break; cli_dh_pos = i; serv_dh_idx = j; - } else { + } else if (IS_EC(group->pk)) { if (cli_ec_pos != -1) break; cli_ec_pos = i; -- cgit v1.2.1