mirror of
https://github.com/chatmail/relay.git
synced 2026-05-10 16:04:37 +00:00
dovecot: enable authentication cache
This commit is contained in:
@@ -59,7 +59,7 @@ def handle_dovecot_request(msg, db):
|
||||
if short_command == "L": # LOOKUP
|
||||
parts = msg[1:].split("\t")
|
||||
keyname, user = parts[:2]
|
||||
namespace, type, arg = keyname.split("/", 3)
|
||||
namespace, type, *args = keyname.split("/")
|
||||
reply_command = "F"
|
||||
res = ""
|
||||
if namespace == "shared":
|
||||
@@ -70,7 +70,7 @@ def handle_dovecot_request(msg, db):
|
||||
else:
|
||||
reply_command = "N"
|
||||
elif type == "passdb":
|
||||
res = lookup_passdb(db, user, password=arg)
|
||||
res = lookup_passdb(db, user, password=args[0])
|
||||
if res:
|
||||
reply_command = "O"
|
||||
else:
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
uri = proxy:/run/dovecot/doveauth.socket:auth
|
||||
iterate_disable = yes
|
||||
default_pass_scheme = plain
|
||||
password_key = passdb/%w
|
||||
password_key = passdb/%w/%u
|
||||
user_key = userdb/%u
|
||||
@@ -8,6 +8,7 @@ auth_verbose = yes
|
||||
auth_debug = yes
|
||||
auth_debug_passwords = yes
|
||||
auth_verbose_passwords = plain
|
||||
auth_cache_size = 100M
|
||||
|
||||
# Authentication for system users.
|
||||
passdb {
|
||||
|
||||
Reference in New Issue
Block a user