ldap_auth.ini 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. [httpd_global_handlers]
  2. _session = {ldap_auth, handle_session_req}
  3. [httpd]
  4. authentication_handlers = {couch_httpd_auth, cookie_authentication_handler}, {ldap_auth, handle_basic_auth_req}, {ldap_auth, handle_admin_role}
  5. [ldap_auth]
  6. ; NOTE: for all of the following configurations, if the key is suffixed in "DN", ldap_auth
  7. ; will expect you to provide a real LDAP Distinguished Name.
  8. ; Enable SSL to the LDAP server.
  9. UseSsl = false
  10. ; The LDAP server to use for searches and authentication.
  11. LdapServer = ldap.example.com
  12. ; The DN to narrow the scope of searches for users and groups.
  13. BaseDN = DC=example,DC=com
  14. ; ldap_auth will use this user DN and password to search for users trying to authenticate.
  15. ; if you have anonymous LDAP queries enabled (not reccomended) you may simply provide the
  16. ; `anon` CN and a blank password.
  17. SearchUserDN = CN=ldapsearch,CN=Users,DC=example,DC=com
  18. SearchUserPassword = ldapsearch_password_here
  19. ; On ActiveDirectory, you might choose from:
  20. ; - sAMAccountName, e.g. jsmith
  21. ; - userPrincipalName, e.g. jsmith@example.com
  22. ; NOTE: if you use userPrincipalName, be sure to URL-encode the username when using basic auth.
  23. ; e.g. http://jsmith%40example.com:password@example.com:5984
  24. UserDNMapAttr = sAMAccountName
  25. ; The LDAP attribute of the group to use as the role name.
  26. GroupDNMapAttr = name
  27. ; The role to grant system administrative privileges to.
  28. ; If you include {ldap_auth, handle_admin_role} in your authentication_handlers, it will
  29. ; grant the system admin role to anyone who has this role assigned. BE CAREFUL.
  30. SystemAdminRoleName = admin