Setting up LDAP for user authentication

by @im_a_muppet on January 29, 2008

OpenLDAP was already installed on my server.

I started LDAP by

  slapd -h ldap:///

I than set it up by

  ldapadd -x -h localhost -D cn=Manager,dc=epl,dc=willspics,dc=com -w secret -f users.ldif

Where the contents of my users.ldif file is

  dn: ou=people,dc=epl,dc=willspics,dc=com
  objectclass: organizationalUnit
  ou: people

  dn: uid=wmerna01,ou=people,dc=epl,dc=willspics,dc=com
  cn: Will Mernagh
  sn: Mernagh
  givenname: Will
  objectclass: top
  objectclass: person
  objectclass: organizationalPerson
  objectclass: inetOrgPerson
  ou: comp190Team2
  ou: People
  l: Tufts
  uid: wmerna01
  mail: wmerna01@cs.tufts.edu
  userpassword: xxxxxx

That is it. I can now browse it using phpLDAPadmin

blog comments powered by Disqus
Tweet