Version 3


Created by: Stephan Borg, Last modification: 08 Jul 2005 (05:32 UTC) by Stephan Borg

What is LDAP?

From - Lightweight Directory Access Protocol (LDAP) is a protocol for accessing on-line directory services.
Essentially, LDAP directories are online address books, which corporates often use to centralise their contact information. LDAP has been used to perform other functions such as serving DNS, automount directories, authenticating users and many other roles where centralised information is useful.

How does it work?

LDAP stores contacts (people, organisations, departments, etc) using a unique identified called a Distinguished Name (DN). A DN could look like this - cn=Stephan Borg,ou=people,o=bitweaver. DN's must be unique within the directory and are used to segregate contact information on a per department, organisation or any kind of grouping level.
With each DN, an unlimited number of attributes can be associated. This allows pieces of information to be added to a contact in a flexible manner. These attributes are determined by a read-only schema, which is control through the LDAP server. Some example attributes are:
Address Book AttributeLDAP Attribute
Common Namecn
Given namegivenName
Job Titletitle
Web PagelabelURI
Calendar Free/Busy URLcalFBURL
User IDuid
Phone numbertelephoneNumber
Fax numberfacsimileTelephoneNumber
Home PhonehomePhone
Home AddresshomePostalAddress

Talking to LDAP

When you retrieve information from an LDAP server, you submit the DN and optionally, what attributes you want to retrieve. The output is usually presented in the following format:
{CODE()}dn: cn=Stephan Borg,ou=people,o=bitweaver
givenName: Stephan
mobile: 1234 567 890
sn: Borg
uid: wolff_borg
cn: Stephan Borg
o: Bitweaver
objectClass: top
objectClass: inetOrgPerson
objectClass: person
objectClass: organizationalPerson
objectClass: calEntry
Page History
10 Jul 2005 (06:49 UTC)
Added second mail attribute to example
Stephan Borg218.214.1.1135
Current • Source
Stephan Borg218.214.1.1134
View • Compare • Difference • Source
Stephan Borg218.214.1.1133
View • Compare • Difference • Source