use of com.sun.identity.wsfederation.meta.WSFederationCOTUtils in project OpenAM by OpenRock.
the class CircleOfTrustManager method updateWSFedEntityConfig.
/**
* Updates the WSFederation Entity Configuration.
*
* @param realm the realm name.
* @param cotName the circle of trust name.
* @param trustedProviders set of trusted provider names.
* @throws COTException if there is an error updating the configuration.
*/
void updateWSFedEntityConfig(String realm, String cotName, Set trustedProviders) throws COTException {
String classMethod = "COTManager:updateWSFedEntityConfig";
String entityId = null;
WSFederationCOTUtils wsfedCotUtils = new WSFederationCOTUtils(callerSession);
if (trustedProviders != null && !trustedProviders.isEmpty()) {
for (Iterator iter = trustedProviders.iterator(); iter.hasNext(); ) {
entityId = (String) iter.next();
try {
wsfedCotUtils.updateEntityConfig(realm, cotName, entityId);
} catch (WSFederationMetaException sme) {
throw new COTException(sme);
} catch (JAXBException e) {
debug.error(classMethod, e);
String[] data = { e.getMessage(), cotName, entityId, realm };
LogUtil.error(Level.INFO, LogUtil.CONFIG_ERROR_CREATE_COT_DESCRIPTOR, data);
throw new COTException(e);
}
}
}
}
Aggregations