Skip to Main Content

Security Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

LDAPException: error result (50); Insufficient access

807573Oct 7 2008 — edited Oct 10 2008
Hi all,

I am getting the "netscape.ldap.LDAPException: error result (50); Insufficient access" during the .compare() method.Althogh the given user is authenticated properlly.
here is the code which I am using

doAuthenticate(){
	try {
		ld.connect( host, 389);
		ld.authenticate("uid=admin,ou=Administrators,ou=TopologyManagement,o=NetscapeRoot", "admin123");
		this.userdn = "uid=admin,ou=Administrators,ou=TopologyManagement,o=NetscapeRoot";
		LDAPAttribute attr = new LDAPAttribute("uniqueMember", userdn);			
				
		// Test for group membership
		System.out.println("log -5 ==> creating attribute");
		boolean attrMatch = ld.compare(groupdn, attr);
		// Display the test results				
		if (attrMatch) {
			System.out.println("\nIS A GROUP MEMBER!\n");
		} else {
			System.out.println("\nIS NOT A GROUP MEMBER!\n");
		}
		} catch (LDAPReferralException e) {
			// Ignore referrals...
		} catch (LDAPException e) {
			System.out.println(e.toString());
		}finally{
			if ((ld != null) && ld.isConnected()) {
				try {
					ld.disconnect();
					System.out.println("Conection closed");
				} catch (LDAPException e) {
					System.out.println("Error: " + e.toString());
				}
			}
		}
}
Thanks
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details