From 46139267e1e9eaab46364357e9447ca75f29b4f1 Mon Sep 17 00:00:00 2001 From: Nikos Mavrogiannopoulos Date: Sun, 2 Feb 2014 08:50:14 +0100 Subject: [PATCH 4/8] When two initial keywords are specified then treat the second as having the '+' modifier. This will handle SECURE256:SECURE128 the same way as SECURE256:+SECURE128. --- lib/gnutls_priority.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/gnutls_priority.c b/lib/gnutls_priority.c index 875f9b0..6bb02e2 100644 --- a/lib/gnutls_priority.c +++ b/lib/gnutls_priority.c @@ -788,6 +788,7 @@ gnutls_priority_init(gnutls_priority_t * priority_cache, char *broken_list[MAX_ELEMENTS]; int broken_list_size = 0, i = 0, j; char *darg = NULL; + unsigned ikeyword_set = 0; int algo; rmadd_func *fn; bulk_rmadd_func *bulk_fn; @@ -842,7 +843,8 @@ gnutls_priority_init(gnutls_priority_t * priority_cache, } for (; i < broken_list_size; i++) { - if (check_level(broken_list[i], *priority_cache, 0) != 0) { + if (check_level(broken_list[i], *priority_cache, ikeyword_set) != 0) { + ikeyword_set = 1; continue; } else if (broken_list[i][0] == '!' || broken_list[i][0] == '+' -- 1.8.5.3