summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/main/java/com/c2kernel/lookup/ldap/LDAPLookup.java7
-rw-r--r--src/main/resources/LDAPboot.txt3
2 files changed, 3 insertions, 7 deletions
diff --git a/src/main/java/com/c2kernel/lookup/ldap/LDAPLookup.java b/src/main/java/com/c2kernel/lookup/ldap/LDAPLookup.java
index 96ab609..0d3cbd4 100644
--- a/src/main/java/com/c2kernel/lookup/ldap/LDAPLookup.java
+++ b/src/main/java/com/c2kernel/lookup/ldap/LDAPLookup.java
@@ -432,7 +432,7 @@ public class LDAPLookup implements LookupManager{
}
else if (LDAPLookupUtils.existsAttributeValue(entry,"objectclass","cristalrole"))
{ //cristalrole
- thisPath = new RolePath(LDAPDN.explodeDN(dn,true)[0],
+ thisPath = new RolePath(getPathComponents(dn.substring(0, dn.lastIndexOf(mDomainTypeRoot))),
LDAPLookupUtils.getFirstAttributeValue(entry, "jobList").equals("TRUE"));
}
else if (LDAPLookupUtils.existsAttributeValue(entry,"objectclass","aliasObject") ||
@@ -496,7 +496,6 @@ public class LDAPLookup implements LookupManager{
@Override
public Iterator<Path> getChildren(Path path) {
- if (path instanceof RolePath) return ((RolePath)path).getChildren();
String filter = "objectclass=*";
LDAPSearchConstraints searchCons = new LDAPSearchConstraints();
searchCons.setBatchSize(10);
@@ -561,16 +560,14 @@ public class LDAPLookup implements LookupManager{
}
- //NOTE: A role must have at LEAST 1 userDN, cannot be empty...
//Creates a cristalRole
//CristalRole is-a specialized CristalContext which contains multi-valued uniqueMember attribute pointing to cristalagents
@Override
- public RolePath createRole(String roleName, boolean jobList)
+ public RolePath createRole(RolePath rolePath)
throws ObjectAlreadyExistsException, ObjectCannotBeUpdated
{
// create the role
- RolePath rolePath = new RolePath(roleName, jobList);
String roleDN = getFullDN(rolePath);
LDAPEntry roleNode;
try
diff --git a/src/main/resources/LDAPboot.txt b/src/main/resources/LDAPboot.txt
index da74bfd..23ac0ef 100644
--- a/src/main/resources/LDAPboot.txt
+++ b/src/main/resources/LDAPboot.txt
@@ -1,3 +1,2 @@
cn=entity,
-cn=domain,
-cn=agent,cn=domain, \ No newline at end of file
+cn=domain, \ No newline at end of file