Hi,

I'm using perl-ldap-0.3202 on RH FC 2 and Sun ONE Directory Server 5.2 on Solaris 8.

When I run this script:
===========================
#!/usr/bin/perl -w

use Net::LDAP;

$ldap = Net::LDAP->new("server1");
$ldap->bind("cn=Directory Manager,ou=tsl,o=acme,c=com", password=>'temp123');

$result = $ldap->add("uid=ywong,ou=People,ou=tsl,o=telus,c=com",
               attr => [ 'cn' => 'ywong',
                         'GECOS' => 'Yoko Wong',
                         'uid' => 'ywong',
                         'gidNumber' => '10000',
                         'uidNumber' => '16012',
                         'homeDirectory' => '/opt/home/ywong',
                         'objectclass' =>
[ 'top', 'posixaccount', 'account','shadowaccount']
                       ]
          );
$result->code && warn "error: ", $result->error();

====================================

I get this error:

error: Insufficient 'add' privilege to add the entry 'uid=ywong,ou=People,ou=tsl,o=telus,c=com'.

There's no error in the Sun DS logs.

Any ideas??

Thanks,

Paul

Reply via email to