mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-06-03 10:50:20 +00:00
email_server: dovecot: Authenticate using PAM instead of LDAP
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org> Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
parent
cb8c23c28d
commit
afc958a884
@ -1,22 +1,10 @@
|
||||
# Direct edits to this file will be lost!
|
||||
# Manage your settings on Plinth <https://localhost/plinth/apps/email_server>
|
||||
|
||||
# Outlook and Windows Mail works only with LOGIN mechanism, not the standard
|
||||
# PLAIN:
|
||||
auth_mechanisms = plain login
|
||||
|
||||
passdb {
|
||||
driver = ldap
|
||||
args = /etc/dovecot/freedombox-ldap-passdb.conf.ext
|
||||
# Block the default passdb lookup (pam, 10-auth.conf)
|
||||
result_failure = return-fail
|
||||
result_internalfail = return-fail
|
||||
result_success = return-ok
|
||||
}
|
||||
|
||||
userdb {
|
||||
driver = ldap
|
||||
args = /etc/dovecot/freedombox-ldap-userdb.conf.ext
|
||||
# Block the default userdb lookup (passwd, 10-auth.conf)
|
||||
result_failure = return-fail
|
||||
result_internalfail = return-fail
|
||||
result_success = return-ok
|
||||
}
|
||||
# Allow authentication from attempts that provide username as
|
||||
# user@domain.example.
|
||||
auth_username_format = %Ln
|
||||
|
||||
@ -1,8 +0,0 @@
|
||||
# Direct edits to this file will be lost!
|
||||
# Manage your settings on Plinth <https://localhost/plinth/apps/email_server>
|
||||
|
||||
uris = ldap://127.0.0.1
|
||||
base = dc=thisbox
|
||||
|
||||
auth_bind = yes
|
||||
auth_bind_userdn = uid=%u,ou=users,dc=thisbox
|
||||
@ -1,20 +0,0 @@
|
||||
# Direct edits to this file will be lost!
|
||||
# Manage your settings on Plinth <https://localhost/plinth/apps/email_server>
|
||||
|
||||
uris = ldap://127.0.0.1
|
||||
base = dc=thisbox
|
||||
|
||||
user_attrs = \
|
||||
=home=%{ldap:homeDirectory}, \
|
||||
=uid=%{ldap:uidNumber}, \
|
||||
=gid=%{ldap:gidNumber}, \
|
||||
=mail=maildir:~/Maildir:LAYOUT=index
|
||||
|
||||
# Support user lookup by username
|
||||
|
||||
user_filter = (&(objectClass=posixAccount)(uid=%Ln)(!(uidNumber=0)))
|
||||
|
||||
# For doveadm
|
||||
|
||||
iterate_attrs = =user=%{ldap:uid}
|
||||
iterate_filter = (objectClass=posixAccount)
|
||||
Loading…
x
Reference in New Issue
Block a user