# SEE /usr/share/doc/dovecot/example-config/dovecot-ldap.conf.ext # This file is commonly accessed via passdb {} or userdb {} section in # conf.d/auth-ldap.conf.ext # This file is opened as root, so it should be owned by root and mode 0600. # # http://wiki2.dovecot.org/AuthDatabase/LDAP # # NOTE: If you're not using authentication binds, you'll need to give # dovecot-auth read access to userPassword field in the LDAP server. # With OpenLDAP this is done by modifying /etc/ldap/slapd.conf. There should # already be something like this: # access to attribute=userPassword # by dn="" read # add this # by anonymous auth # by self write # by * none # Space separated list of LDAP hosts to use. host:port is allowed too. #hosts = # LDAP URIs to use. You can use this instead of hosts list. Note that this # setting isn't supported by all LDAP libraries. #uris = #>GNUNUX uris = ldaps://%%ldap_server_address #GNUNUX dn = %%ldapclient_remote_user dnpass = %%ldapclient_remote_user_password #GNUNUX tls_cert_file = %%ldap_cert_file tls_key_file = %%ldap_key_file tls_ca_cert_file = %%ldap_ca_file tls_require_cert = hard #>GNUNUX # Use the given ldaprc path. #ldaprc_path = # LDAP library debug level as specified by LDAP_DEBUG_* in ldap_log.h. # -1 = everything. You may need to recompile OpenLDAP with debugging enabled # to get enough output. #debug_level = 0 # Use authentication binding for verifying password's validity. This works by # logging into LDAP server using the username and password given by client. # The pass_filter is used to find the DN for the user. Note that the pass_attrs # is still used, only the password field is ignored in it. Before doing any # search, the binding is switched back to the default DN. #auth_bind = no # If authentication binding is used, you can save one LDAP request per login # if users' DN can be specified with a common template. The template can use # the standard %variables (see user_filter). Note that you can't # use any pass_attrs if you use this setting. # # If you use this setting, it's a good idea to use a different # dovecot-ldap.conf.ext for userdb (it can even be a symlink, just as long as # the filename is different in userdb's args). That way one connection is used # only for LDAP binds and another connection is used for user lookups. # Otherwise the binding is changed to the default DN before each user lookup. # # For example: # auth_bind_userdn = cn=%u,ou=people,o=org # #auth_bind_userdn = #>GNUNUX auth_bind = yes auth_bind_userdn = cn=%u,ou=users,%%ldap_base_dn #GNUNUX user_filter = (&(objectClass=inetOrgPerson)(cn=%u)) #GNUNUX pass_attrs = cn=user pass_filter = (&(objectClass=inetOrgPerson)(cn=%u)) #GNUNUX iterate_attrs = cn=user iterate_filter = (&(objectClass=inetOrgPerson)(cn=%u)) #