From b21ed5c0aa797bb11354b806acc39df6aa94ff02 Mon Sep 17 00:00:00 2001 From: Aaron Jones Date: Wed, 31 Aug 2016 17:06:51 +0000 Subject: [PATCH] MbedTLS: Ciphersuite configuration fixes --- libratbox/src/mbedtls.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/libratbox/src/mbedtls.c b/libratbox/src/mbedtls.c index c9735710..cab71098 100644 --- a/libratbox/src/mbedtls.c +++ b/libratbox/src/mbedtls.c @@ -442,12 +442,12 @@ rb_setup_ssl_server(const char *const certfile, const char *keyfile, return 0; } - if(cipher_list != NULL) + if(cipherlist != NULL) { - // The cipher_list is (const char *) -- we should not modify it - char *const cipher_list_dup = strdup(cipher_list); + // The cipherlist is (const char *) -- we should not modify it + char *const cipherlist_dup = strdup(cipherlist); - if(cipher_list_dup == NULL) + if(cipherlist_dup == NULL) { rb_lib_log("rb_setup_ssl_server: strdup: %s", strerror(errno)); rb_lib_log("rb_setup_ssl_server: will not configure ciphersuites!"); @@ -455,7 +455,7 @@ rb_setup_ssl_server(const char *const certfile, const char *keyfile, else { size_t suites_count = 0; - char *cipher_str = cipher_list_dup; + char *cipher_str = cipherlist_dup; while(*cipher_str != '\0' && suites_count < RB_MAX_CIPHERSUITES) { @@ -492,7 +492,7 @@ rb_setup_ssl_server(const char *const certfile, const char *keyfile, mbedtls_ssl_conf_ciphersuites(&newcfg->client_cfg, newcfg->suites); } - free(cipher_list_dup); + free(cipherlist_dup); } }