public
nobgit
read
NobMail
Based on mailcow: dockerized
Languages
Repository composition by tracked source files.
PHP
49%
JavaScript
35%
HTML
9%
CSS
4%
Shell
2%
Python
1%
Lua
0%
Perl
0%
Ruby
0%
SCSS
0%
Create file
Wiki Documentation
Clone
https://nobgit.com/orgs/nobgit/nobmail.git
ssh://[email protected]:2222/orgs/nobgit/nobmail.git
Commit
new dovecout lua auth - use https
1c73a16c
data/Dockerfiles/dovecot/Dockerfile | 1 +
data/Dockerfiles/dovecot/docker-entrypoint.sh | 8 ++++----
2 files changed, 5 insertions(+), 4 deletions(-)
Diff
diff --git a/data/Dockerfiles/dovecot/Dockerfile b/data/Dockerfiles/dovecot/Dockerfile
index a3558968..a9d4739c 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 f146a8a0..be9dd4d4 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),