aboutsummaryrefslogtreecommitdiffstats
path: root/core/certmanager.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2022-02-10 17:15:55 +0100
committerKim Alvefur <zash@zash.se>2022-02-10 17:15:55 +0100
commit406b90d31deb1578a545401e0be190d11f2f6aba (patch)
tree5f3f51873b72c131576570d713aa19cfc2229fbe /core/certmanager.lua
parent73d1bb12184cd5bc91c5996ecc574149d9637d73 (diff)
downloadprosody-406b90d31deb1578a545401e0be190d11f2f6aba.tar.gz
prosody-406b90d31deb1578a545401e0be190d11f2f6aba.zip
core.certmanager: Turn soft dependency on LuaSec into a hard
The default network backend server_epoll already requires LuaSec so Prosody won't even start without it, so we can get rid of these lines here too.
Diffstat (limited to 'core/certmanager.lua')
-rw-r--r--core/certmanager.lua16
1 files changed, 3 insertions, 13 deletions
diff --git a/core/certmanager.lua b/core/certmanager.lua
index 684b240c..2585716f 100644
--- a/core/certmanager.lua
+++ b/core/certmanager.lua
@@ -6,20 +6,10 @@
-- COPYING file in the source package for more information.
--
-local softreq = require"util.dependencies".softreq;
-local ssl = softreq"ssl";
-if not ssl then
- return {
- create_context = function ()
- return nil, "LuaSec (required for encryption) was not found";
- end;
- reload_ssl_config = function () end;
- }
-end
-
+local ssl = require "ssl";
local configmanager = require "core.configmanager";
local log = require "util.logger".init("certmanager");
-local ssl_context = ssl.context or softreq"ssl.context";
+local ssl_context = ssl.context or require "ssl.context";
local ssl_newcontext = ssl.newcontext;
local new_config = require"util.sslconfig".new;
local stat = require "lfs".attributes;
@@ -48,7 +38,7 @@ end
local luasec_major, luasec_minor = ssl._VERSION:match("^(%d+)%.(%d+)");
local luasec_version = tonumber(luasec_major) * 100 + tonumber(luasec_minor);
-local luasec_has = ssl.config or softreq"ssl.config" or {
+local luasec_has = ssl.config or {
algorithms = {
ec = luasec_version >= 5;
};