Hello fellow Vault users. I'm working on getting our staging Vault cluster setup to use LDAP authentication. We're running OpenLDAP with TLS enabled. I'm using a system read-only account within LDAP to bind to LDAP and perform checks. The LDAP configuration I've got looks like the following:
url="ldaps://<LDAP URL>" \
binddn="<system account user>" \
bindpass='<password>' \
userdn="ou=People,dc=<domain>,dc=<tld>" \
userattr=cn \
groupdn="cn=vault_users,ou=Groups,dc=<domain>,dc=<tld>" \
groupfilter="(&(objectClass=inetOrgPerson)(cn={{.Username}}))" \
groupattr="cn" \
certificate=<ca-bundle-file> \
insecure_tls=false
Within LDAP we have a structure that looks like:
<FQDN of Domain>:
- OU of People (contains a list of all users in LDAP)
-- CN of user object is what is being used to authenticate
- OU of Groups (all the various groups)
-- CN of vault_users (group that signifies the ability to access Vault and mapped to a policy)
Several user objects are members of the vault_users group, myself included.
When I attempt to log into Vault using LDAP credentials, I receive an error 32 - object not found. It appears to be binding correctly to LDAP (e.g. not an incorrect port as specified in a previous post) because when I change the bindpass to gibberish, I get an error 49 - incorrect credentials.
I suspect that the error lies in the group filter / group attr setup, but I'm not sure how to troubleshoot this. Using Apache Directory Studio, I can validate all the userdn / groupdn config is correct. The Vault logs don't offer much help.
The configuration I'm hoping to acheive is to login with a username/password, which belongs to a user in LDAP, and only allow access if they belong to the vault_users group. Does the config I listed above match my goal?
Thanks,
Matthew