OpenLDAP and FreeIPA¶
The defaults fit Active Directory. For other directories, set the filters and the name attribute.
ldap:
url: ldaps://ldap.example.com
base_dn: dc=example,dc=com
bind_dn: cn=bastionxp-ca,ou=services,dc=example,dc=com
bind_password_file: /etc/bastionxp-ca/ldap-password
user_filter: (&(objectClass=posixAccount)(uid={username}))
username_attribute: uid
group_base_dn: ou=groups,dc=example,dc=com
group_filter: (&(objectClass=groupOfNames)(member={user_dn}))
ldap:
url: ldaps://ipa.example.com
ca_file: /etc/ipa/ca.crt
base_dn: cn=accounts,dc=example,dc=com
bind_dn: uid=bastionxp-ca,cn=sysaccounts,cn=etc,dc=example,dc=com
bind_password_file: /etc/bastionxp-ca/ldap-password
user_filter: (&(objectClass=posixAccount)(uid={username}))
username_attribute: uid
group_base_dn: cn=groups,cn=accounts,dc=example,dc=com
group_filter: (&(objectClass=groupOfNames)(member={user_dn}))
{username}is what the person types (escaped before it goes into the filter);{user_dn}is the DN of the entry found.groupOfNameswithmember={user_dn}gives direct membership only.user_filtermust contain{username},group_filtermust contain{user_dn}; both must be valid LDAP filters.- With
username_attribute: uid,{username}and{short_username}are both the uid (it has no@).