public class LoaderLdapElUtils extends Object
Constructor and Description |
---|
LoaderLdapElUtils() |
Modifier and Type | Method and Description |
---|---|
static String |
convertAdMemberDnToSpecificValue(String dn,
String baseDn,
String grouperBaseStem,
boolean idOrIdentifier)
convert a user dn to a user CN, and a group dn to a group ID or Uuid
|
static String |
convertDnToGroupName(String dn,
String baseDn,
String grouperBaseStem)
convert a DN to a group name
|
static String |
convertDnToSpecificValue(String dn)
convert from uid=someapp,ou=people,dc=myschool,dc=edu
to someapp
|
static String |
convertDnToSpecificValueOrGroup(String dn,
String groupPrefix,
String groupSuffix,
boolean createGroupIfNotThere,
boolean idOrIdentifier)
convert from uid=someapp,ou=people,dc=myschool,dc=edu to someapp and allow groups
|
static String |
convertDnToSpecificValueTest(String dn,
String subjectIdToReturnGroup,
String groupToCreateReturn)
test case showing a transformation where if the dn is the subjectIdToReturnGroup then make sure groupToCreateReturn
exists and return its ID
|
static String |
convertDnToSubPath(String dn,
String baseDn,
String searchDn)
convert from uid=someapp,ou=people,dc=myschool,dc=edu
baseDn is edu
searchDn is myschool
to people:someapp
|
public static String convertDnToSpecificValue(String dn)
dn
- public static String convertDnToSpecificValueOrGroup(String dn, String groupPrefix, String groupSuffix, boolean createGroupIfNotThere, boolean idOrIdentifier)
dn
- full dnallowGroups
- if groups are allowedgroupSuffix
- group suffix e.g. ,OU=Groups,DC=dev,DC=umontreal,DC=cagroupPrefix
- group prefix e.g. umontreal:adgroups:
if null then no prefixcreateGroupIfNotThere
- if we should see if group exists and if not, createidOrIdentifier
- true for Id (uuid), false for Identifier of group (name)public static String convertDnToSubPath(String dn, String baseDn, String searchDn)
dn
- baseDn
- if there is one, take it offsearchDn
- if there is one after the baseDn is off, take it offpublic static String convertDnToSpecificValueTest(String dn, String subjectIdToReturnGroup, String groupToCreateReturn)
dn
- subjectIdToReturnGroup
- groupToCreateReturn
- public static String convertAdMemberDnToSpecificValue(String dn, String baseDn, String grouperBaseStem, boolean idOrIdentifier)
baseDn
- e.g. OU=People,DC=devsim,DC=umontreal,DC=cadn
- of group membergrouperBaseStem
- is the base stem where the groups go. e.g. my:groups:idOrIdentifier
- true for id (group id), false for identifier (group name)public static String convertDnToGroupName(String dn, String baseDn, String grouperBaseStem)
dn
- baseDn
- e.g. OU=People,DC=devsim,DC=umontreal,DC=cagrouperBaseStem
- is the base stem where the groups go. e.g. my:groups:Copyright © 2016 Internet2. All rights reserved.