I searched everywhere for a solution to my problem, but still could not find it. I have two simple files: sladp.conf and mytree.ldif, and when I try to add something to mytree.ldif, it keeps asking me about the password (which I think roopw is defined in slapd.conf), but it doesn't work, I really need help with this.
These are my files:
slapd.conf
database dbd suffix "dc=ers,dc=uminho,dc=pt" rootdn "cn=Manager,dc=ers,dc=uminho,dc=pt" rootpw ersadmin directory /usr/local/var/openldap-data
mytree.ldif
dn: dc=ers, dc=uminho, dc=pt objectclass: dcObject objectclass: organization o: ERS dc: ers dn: cn=Manager,dc=ers,dc=uminho,dc=pt objectclass: organizationalRole cn: Manager
And here is what I am trying to do and my answer is:
sudo ldapadd -x -D "cn=Manager,dc=ers,dc=uminho,dc=pt" -W -f /etc/ldap/mytree.ldif Enter LDAP Password: ldap_bind: Invalid credentials (49)
I already tried to encrypt the password using
slappasswd -h {SHA} -s ersadmin
and modifying my slapd.conf file
password-hash {SHA} rootpw {SHA}pLEBIPx4rW3eebpwACBGAZkNH4CVBRGW
but it didnβt work. Thanks in advance.