Skip to content

Commit

Permalink
treat ECDHE,RSA cipher suite list as mixed TLS 1.3 and pre TLS 1.3
Browse files Browse the repository at this point in the history
  • Loading branch information
JacobBarthelmeh committed Jan 5, 2023
1 parent a3e085f commit ab33788
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions src/ssl.c
Original file line number Diff line number Diff line change
Expand Up @@ -11765,6 +11765,28 @@ static int CheckcipherList(const char* list)
break;
}
}

#if defined(OPENSSL_EXTRA) || defined(OPENSSL_ALL)
/* check if mixed due to names like RSA:ECDHE+AESGCM etc. */
if (ret != 0) {
char* subStr = name;
char* subStrNext;

do {
subStrNext = XSTRSTR(subStr, "+");

if ((XSTRCMP(subStr, "ECDHE") == 0) ||
(XSTRCMP(subStr, "RSA") == 0)) {
return 0;
}

if (subStrNext && (XSTRLEN(subStrNext) > 0)) {
subStr = subStrNext + 1; /* +1 to skip past '+' */
}
} while (subStrNext != NULL);
}
#endif

if (findTLSv13Suites == 1 && findbeforeSuites == 1) {
/* list has mixed suites */
return 0;
Expand Down

0 comments on commit ab33788

Please sign in to comment.