diff --git a/data/Dockerfiles/dovecot/Dockerfile b/data/Dockerfiles/dovecot/Dockerfile index a35589689..a9d4739cf 100644 --- a/data/Dockerfiles/dovecot/Dockerfile +++ b/data/Dockerfiles/dovecot/Dockerfile @@ -34,6 +34,7 @@ RUN addgroup -g 5000 vmail \ icu-data-full \ mariadb-connector-c \ gcompat \ + lua-sec \ mariadb-client \ perl \ perl-ntlm \ diff --git a/data/Dockerfiles/dovecot/docker-entrypoint.sh b/data/Dockerfiles/dovecot/docker-entrypoint.sh index f146a8a01..be9dd4d44 100755 --- a/data/Dockerfiles/dovecot/docker-entrypoint.sh +++ b/data/Dockerfiles/dovecot/docker-entrypoint.sh @@ -136,8 +136,8 @@ function auth_password_verify(request, password) json = require "json" ltn12 = require "ltn12" - http = require "socket.http" - http.TIMEOUT = 5 + https = require "ssl.https" + https.TIMEOUT = 5 mysql = require "luasql.mysql" env = mysql.mysql() con = env:connect("__DBNAME__","__DBUSER__","__DBPASS__","localhost") @@ -150,7 +150,7 @@ function auth_password_verify(request, password) local res = {} -- check against mailbox passwds - local b, c = http.request { + local b, c = https.request { method = "POST", url = "https://nginx/api/v1/process/login", source = ltn12.source.string(req_json), @@ -181,7 +181,7 @@ function auth_password_verify(request, password) req.protocol.ignore_hasaccess = true end - local b, c = http.request { + local b, c = https.request { method = "POST", url = "https://nginx/api/v1/process/login", source = ltn12.source.string(req_json),