From c2da2e47e19128f797ddc37c3d1167adef3af875 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Mon, 14 Apr 2014 23:34:35 +0200 Subject: certmanager: Concatenate cipher list if given as a table --- core/certmanager.lua | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/core/certmanager.lua b/core/certmanager.lua index 6a53f5b2..879d6131 100644 --- a/core/certmanager.lua +++ b/core/certmanager.lua @@ -15,6 +15,7 @@ local tostring = tostring; local pairs = pairs; local type = type; local io_open = io.open; +local t_concat = table.concat; local prosody = prosody; local resolve_path = configmanager.resolve_relative_path; @@ -87,6 +88,11 @@ function create_context(host, mode, user_ssl_config) end end + -- Allow the cipher list to be a table + if type(user_ssl_config.ciphers) == "table" then + user_ssl_config.ciphers = t_concat(user_ssl_config.ciphers, ":") + end + if mode == "server" then if not user_ssl_config.key then return nil, "No key present in SSL/TLS configuration for "..host; end if not user_ssl_config.certificate then return nil, "No certificate present in SSL/TLS configuration for "..host; end -- cgit v1.2.3