Search code examples
ldapopenldap

OpenLDAP Won't Set Encyrpted Password: attribute 'userPassword' is not present in entry


I'm trying to set up an OpenLDAP server in a docker container on my local network. I got it set up and connected using Apache Directory Studio and created some posix groups/accounts with no trouble. The problem is, I can add a plaintext userPassword for my users but trying to use any type of encryption scheme results in the error:

entry failed schema check: value of naming attribute 'userPassword' is not present in entry

Other notes about my configuration:

  • I'm using a self signed certificate using the LAN address to connect over LDAPS
  • Using the docker image osixia/openldap

I can provide any other configurations if needed.


Solution

  • Normally you would install the ppolicy module and set the "ppolicy_hash_cleartext" variable in slapd.conf to enable password hashing. Since you're using a docker container this will work slightly differently.

    Check out the following page from the docker image you are using: https://github.com/osixia/docker-openldap/issues/208