wheelybird / ldap-user-manager

A PHP web-based interface for LDAP user account management and self-service password change.
MIT License
477 stars 106 forks source link

Unable to login with admin account during setup #187

Open verashanky opened 1 year ago

verashanky commented 1 year ago

I am trying to use ldap-user-manager along with bitnami openldap server with the following config. Containers are up and running successfully, but when I load the setup URL and login with admin password, I get the following error in UI: Problem: Failed to bind as cn=admin,dc=company,dc=network

Wondering what I'm missing here?

Docker-compose.yml ` version: '3'

networks: openldap: name: openldap

services: openldap: image: bitnami/openldap:latest restart: unless-stopped ports:

volumes: openldap_data: driver: local `

Log file: 63d33c25.2c682d7e 0x7fa6dadfe700 conn=1574 fd=14 TLS established tls_ssf=256 ssf=256 tls_proto=TLSv1.3 tls_cipher=TLS_AES_256_GCM_SHA384 63d33c25.2c69c536 0x7fa6f0e39700 conn=1574 op=1 BIND dn="cn=admin,dc=company,dc=network" method=128 63d33c25.2c6b3dee 0x7fa6f0e39700 conn=1574 op=1 RESULT tag=97 err=49 qtime=0.000014 etime=0.000129 text= 63d33c25.2c6e0f3c 0x7fa6da5fd700 conn=1574 op=2 UNBIND 63d33c25.2c6f638f 0x7fa6da5fd700 conn=1574 fd=14 closed

wheelybird commented 1 year ago

Hi. Are you sure that's the actual Docker compose config you're using? I get an error for the networks section - name: not expected. Fixing that I can get the containers to run, but ldap-user-manager can't connect to the openldap container. This is because the bitnami container is configured to start slapd on port 1389 rather than 389. So if I change LDAP_URI to ldap://openldap:1389 it works. This doesn't match with the logs you've pasted though - if you were having this issue you'd see Failed to bind to ldap://openldap as cn=admin,dc=company,dc=network: Can't contact LDAP server in the logs, and wouldn't see any slapd logs. In fact err=49 suggests a wrong bind DN or password, which suggests that ldap-user-manager can connect but the password is wrong. Perhaps you set up the LDAP container initially with a different password and didn't subsequently update it?

Jorricks commented 9 months ago

You should set - LDAP_URI=ldap://openldap:1389 inedeed.