Comparison

core/portmanager.lua @ 6980:daaa52b3f45f

portmanager: Lower the priority of module-supplied TLS options
author Kim Alvefur <zash@zash.se>
date Tue, 08 Dec 2015 20:12:38 +0100
parent 6788:d64c1f3c7e2e
child 7078:ec17115e3721
comparison
equal deleted inserted replaced
6979:0ce2b400663b 6980:daaa52b3f45f
109 -- Create SSL context for this service/port 109 -- Create SSL context for this service/port
110 if service_info.encryption == "ssl" then 110 if service_info.encryption == "ssl" then
111 local global_ssl_config = config.get("*", "ssl") or {}; 111 local global_ssl_config = config.get("*", "ssl") or {};
112 local prefix_ssl_config = config.get("*", config_prefix.."ssl") or global_ssl_config; 112 local prefix_ssl_config = config.get("*", config_prefix.."ssl") or global_ssl_config;
113 ssl, err = certmanager.create_context(service_info.name.." port "..port, "server", 113 ssl, err = certmanager.create_context(service_info.name.." port "..port, "server",
114 service_info.ssl_config or {},
115 prefix_ssl_config[interface], 114 prefix_ssl_config[interface],
116 prefix_ssl_config[port], 115 prefix_ssl_config[port],
117 prefix_ssl_config, 116 prefix_ssl_config,
117 service_info.ssl_config or {},
118 global_ssl_config[interface], 118 global_ssl_config[interface],
119 global_ssl_config[port]); 119 global_ssl_config[port]);
120 if not ssl then 120 if not ssl then
121 log("error", "Error binding encrypted port for %s: %s", service_info.name, error_to_friendly_message(service_name, port_number, err) or "unknown error"); 121 log("error", "Error binding encrypted port for %s: %s", service_info.name, error_to_friendly_message(service_name, port_number, err) or "unknown error");
122 end 122 end