use of com.sun.enterprise.connectors.authentication.EisBackendPrincipal in project Payara by payara.
the class SecurityMapUtils method generateResourcePrincipal.
/**
* Creates the ResourcePrincipal object from the given securityMap
*
* @param securityMap SecurityMap
* @return created ResourcePrincipal object
*/
private static ResourcePrincipal generateResourcePrincipal(ConnectorSecurityMap securityMap) {
EisBackendPrincipal backendPrincipal = securityMap.getBackendPrincipal();
String userName = backendPrincipal.getUserName();
String password = backendPrincipal.getPassword();
return new ResourcePrincipal(userName, password);
}
use of com.sun.enterprise.connectors.authentication.EisBackendPrincipal in project Payara by payara.
the class SecurityMapUtils method convertSecurityMapConfigBeanToSecurityMap.
private static ConnectorSecurityMap convertSecurityMapConfigBeanToSecurityMap(SecurityMap securityMap) {
String name = securityMap.getName();
List<String> principalList = new ArrayList<String>();
for (String p : securityMap.getPrincipal()) {
principalList.add(p);
}
List<String> userGroupList = new ArrayList<String>();
for (String g : securityMap.getUserGroup()) {
userGroupList.add(g);
}
EisBackendPrincipal backendPrincipal = transformBackendPrincipal(securityMap.getBackendPrincipal());
return new ConnectorSecurityMap(name, principalList, userGroupList, backendPrincipal);
}
Aggregations