mirror of
https://github.com/chatmail/relay.git
synced 2026-05-10 16:04:37 +00:00
Compare commits
1 Commits
fix-cmdepl
...
link2xt/fi
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
50b9c3738b |
@@ -91,7 +91,7 @@ def lookup_passdb(db, config: Config, user, cleartext_password):
|
||||
VALUES (?, ?, ?)"""
|
||||
conn.execute(q, (user, encrypted_password, int(time.time())))
|
||||
return dict(
|
||||
home=f"/home/vmail/{user}",
|
||||
home=f"/home/vmail/mail/{config.mail_domain}/{user}",
|
||||
uid="vmail",
|
||||
gid="vmail",
|
||||
password=encrypted_password,
|
||||
|
||||
@@ -61,7 +61,10 @@ def test_handle_dovecot_request(db, example_config):
|
||||
assert res
|
||||
assert res[0] == "O" and res.endswith("\n")
|
||||
userdata = json.loads(res[1:].strip())
|
||||
assert userdata["home"] == "/home/vmail/some42123@chat.example.org"
|
||||
assert (
|
||||
userdata["home"]
|
||||
== "/home/vmail/mail/chat.example.org/some42123@chat.example.org"
|
||||
)
|
||||
assert userdata["uid"] == userdata["gid"] == "vmail"
|
||||
assert userdata["password"].startswith("{SHA512-CRYPT}")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user