use of org.pentaho.platform.engine.security.DefaultLdapRoleMapper in project pentaho-platform by pentaho.
the class DefaultLdapUserRoleListServiceTest method getDefaultLdapUserRoleListService.
private DefaultLdapUserRoleListService getDefaultLdapUserRoleListService(Map<String, String> roleMap) {
IAuthenticationRoleMapper roleMapper = new DefaultLdapRoleMapper(roleMap);
DefaultLdapUserRoleListService defaultLdapUserRoleListService = new DefaultLdapUserRoleListService(null, null, roleMapper);
defaultLdapUserRoleListService.setExtraRoles(Arrays.asList(ROLES));
defaultLdapUserRoleListService.setUserNameUtils(new DefaultTenantedPrincipleNameResolver());
defaultLdapUserRoleListService.setRoleNameUtils(new DefaultTenantedPrincipleNameResolver("_"));
return defaultLdapUserRoleListService;
}
Aggregations