GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
AddressBook::DB::LDAP(3) User Contributed Perl Documentation AddressBook::DB::LDAP(3)

AddressBook::DB::LDAP - Backend for AddressBook to use LDAP.

  use AddressBook;
  $a = AddressBook->new(source => "LDAP:hostname/ou=People,dc=example,dc=com",
                        username => "user", password => "pass");
  $a->add($entry) || die $a->code;

The Net::LDAP library module is required in order to use this package.

AddressBook::DB::LDAP supports random access backend database methods.

Behavior can be modified using the following options:

key_fields
A list of LDAP attribute names (not cannonical names) which can be used to uniquely identify an entry.
hostname
The LDAP host to which to connect.
base
The base for LDAP queries.
objectclass
The objectclass for AddressBook entries.
username
An LDAP dn to use for accessing the server.
password
dn_calculate
A perl expression which, when eval'd returns a valid LDAP "dn" (omitting the "base" part of the dn). Other attributes may be referenced as "$<attr>".

For example, if LDAP entries have a dn like: "cn=John Doe,mail=jdoe@mail.com", then use the following:

  dn_calculate="'cn=' . $cn . ',mail=' . $mail"
    

Any of these options may be specified in the constructor, or in the configuration file.

  $a = AddressBook->new(source => "LDAP");
  $a = AddressBook->new(source => "LDAP:localhost/ou=People,dc=example,dc=com");
  $a = AddressBook->new(source => "LDAP",
                        hostname=>"localhost",
                        base=>"o=test"
                        );

Any or all options may be specified in the constructor, or in the configuration file.

For syncronization purposes, all records are timestamped using the "modifytimestamp" LDAP attribute. If the record has no "modifytimestamp", "createtimestamp" is used. If there is no "createtimestamp", the current time is used.

Mark A. Hershberger, <mah@everybody.org> David L. Leigh, <dleigh@sameasiteverwas.net>

AddressBook, AddressBook::Config, AddressBook::Entry.

Net::LDAP

2001-01-22 perl v5.32.1

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.