Open LDAP

From Cramsession
Revision as of 05:36, 23 September 2025 by Mflavell (talk | contribs) (Created page with "= Creating and ADMIN user = == Generate a SHA password == slappasswd provide password Save the resulting SHA == Create the LDIF File == Create a file in nano dn: uid=adminuser,dc=southbaytechnology,dc=com objectClass: inetOrgPerson objectClass: organizationalPerson objectClass: person cn: Admin User sn: User uid: admin userPassword: {SSHA}7x6qOrJlHQI+mONuYn+W2HTG/xHQVEL2 == Add the user == ldapadd -x -W -D "cn=admin,dc=southbaytechnology,dc=com" -f admi...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search
✍️ Verified Author: MflavellClick to view professional profile & credentials

Creating and ADMIN user

Generate a SHA password

slappasswd

provide password

Save the resulting SHA

Create the LDIF File

Create a file in nano

dn: uid=adminuser,dc=southbaytechnology,dc=com
objectClass: inetOrgPerson
objectClass: organizationalPerson
objectClass: person
cn: Admin User
sn: User
uid: admin
userPassword: {SSHA}7x6qOrJlHQI+mONuYn+W2HTG/xHQVEL2

Add the user

ldapadd -x -W -D "cn=admin,dc=southbaytechnology,dc=com" -f admin.ldif

Grant Admin Rights

Create LDIF File

   dn: olcDatabase={1}hdb,cn=config
   changetype: modify
   replace: olcRootDN
   olcRootDN: uid=adminuser,dc=southbaytechnology,dc=com

Save changes

ldapmodify -Y EXTERNAL -H ldapi:/// -f rootdn_change.ldif