浏览代码

tls: fix setting cipher suites for tls verions prior to 1.3

(cherry picked from commit 84a29ac892d1097a8d08a4853fd2749ee039405c)
Ovidiu Sas 2 月之前
父节点
当前提交
c522cff31e
共有 1 个文件被更改,包括 6 次插入6 次删除
  1. 6 6
      src/modules/tls/tls_domain.c

+ 6 - 6
src/modules/tls/tls_domain.c

@@ -749,12 +749,12 @@ static int set_cipher_list(tls_domain_t *d)
 				ERR("%s: Failure to set SSL context cipher suites \"%s\"\n",
 						tls_domain_str(d), cipher_list);
 				return -1;
-			} else {
-				if(SSL_CTX_set_cipher_list(d->ctx[i], cipher_list) == 0) {
-					ERR("%s: Failure to set SSL context cipher list \"%s\"\n",
-							tls_domain_str(d), cipher_list);
-					return -1;
-				}
+			}
+		} else {
+			if(SSL_CTX_set_cipher_list(d->ctx[i], cipher_list) == 0) {
+				ERR("%s: Failure to set SSL context cipher list \"%s\"\n",
+						tls_domain_str(d), cipher_list);
+				return -1;
 			}
 		}
 #endif