From: Murugan K G <mur...@ya...> - 2002-06-05 09:57:59
|
Hi LDAP gurus I am trying to develop one perl module for "RefreshLDAPServerRequest" eDirectory extension as below. While executing this script , i am getting LDAP_INSUFFICIENT_ACCESS message code and Insufficient access message error. Here i logged in with admin rights only. After that also , i am getting the same. Any help greatly appriciated. Am i doing anything in the script?. Regards K.Murugan use Convert::ASN1; use Net::LDAP qw(:all); use Net::LDAP::Util qw(ldap_error_name ldap_error_text) ; # use for Error handling require Net::LDAP::Extension; require Net::LDAP::Message; $ldap = Net::LDAP->new("xxx.xx.xxx.xxx") or die "$@"; print $ldap->{error}; $asn = Convert::ASN1->new; $ldap->bind('username',password => 'password') or die "Not able to bind"; my $mesg = $ldap->message('Net::LDAP::Extension' => $arg); $ldap->start_tls(); $mesg->encode ( extendedReq =>{ requestName => "2.16.840.1.113719.1.27.100.9", requestValue => null } )or die "Not able to encode the extended values\n"; $response=$ldap->_sendmesg($mesg) or die "Not able to send message\n"; $mesg->sync(); if( $mesg->code ne LDAP_SUCCESS) { print "LDAP ERROR\n "; print "The response name is ". $response->{responseName}; $ldap->unbind(); } else { print "The response name is ". $response->{responseName}; print "The junk\n".$response->{response}; $ldap->unbind(); } print "Ldap extension operation result", ldap_error_name($mesg->code),"\n"; print $mesg->error; # print $mesg->mesg_id; =head $result=Net::LDAP::Extension::response_name($mesg); $result=Net::LDAP::Extension::response($mesg); print $result; $asn = Convert::ASN1->new; print $asn->decode($response->{response}->{identity}) or die "Not able to decode the message\n"; # print "The value of the response name is ".$out->{responseName}; =cut __________________________________________________ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com |