use of com.sun.identity.console.federation.model.SAMLv2Model in project OpenAM by OpenRock.
the class SAMLv2PDPViewBean method handleButton1Request.
public void handleButton1Request(RequestInvocationEvent event) throws ModelControlException {
retrieveCommonProperties();
try {
SAMLv2Model model = (SAMLv2Model) getModel();
AMPropertySheet ps = (AMPropertySheet) getChild(PROPERTY_ATTRIBUTES);
// update standard metadata
Map origStdMeta = model.getPDPDescriptor(realm, entityName);
Map stdValues = ps.getAttributeValues(origStdMeta, false, model);
model.updatePDPDescriptor(realm, entityName, stdValues);
//update extended metadata
Map origExtMeta = model.getPDPConfig(realm, entityName, location);
Map extValues = ps.getAttributeValues(model.getXacmlPDPExtendedMetaMap(), false, model);
origExtMeta.putAll(extValues);
model.updatePDPConfig(realm, entityName, location, origExtMeta);
setInlineAlertMessage(CCAlert.TYPE_INFO, "message.information", "samlv2.entityDescriptor.provider.pdp.updated");
} catch (AMConsoleException e) {
setInlineAlertMessage(CCAlert.TYPE_ERROR, "message.error", e.getMessage());
}
forwardTo();
}
use of com.sun.identity.console.federation.model.SAMLv2Model in project OpenAM by OpenRock.
the class SAMLv2PDPViewBean method beginDisplay.
public void beginDisplay(DisplayEvent event) throws ModelControlException {
super.beginDisplay(event);
SAMLv2Model model = (SAMLv2Model) getModelInternal();
populateValue();
}
use of com.sun.identity.console.federation.model.SAMLv2Model in project OpenAM by OpenRock.
the class SAMLv2AttrQueryViewBean method beginDisplay.
public void beginDisplay(DisplayEvent event) throws ModelControlException {
AMPropertySheet ps = (AMPropertySheet) getChild(PROPERTIES);
ps.init();
SAMLv2Model model = (SAMLv2Model) getModel();
ps.setAttributeValues(getStandardAttrQueryValues(), model);
ps.setAttributeValues(getExtendedAttrQueryValues(), model);
}
use of com.sun.identity.console.federation.model.SAMLv2Model in project OpenAM by OpenRock.
the class SAMLv2AttrQueryViewBean method getExtendedAttrQueryValues.
private Map getExtendedAttrQueryValues() {
Map extendedValues = new HashMap();
try {
SAMLv2Model model = (SAMLv2Model) getModel();
Map attr = model.getExtendedAttrQueryAttributes(realm, entityName);
Set entries = attr.entrySet();
Iterator iterator = entries.iterator();
while (iterator.hasNext()) {
Map.Entry entry = (Map.Entry) iterator.next();
extendedValues.put((String) entry.getKey(), convertListToSet((List) entry.getValue()));
}
} catch (AMConsoleException e) {
setInlineAlertMessage(CCAlert.TYPE_ERROR, "message.error", e.getMessage());
}
return extendedValues;
}
use of com.sun.identity.console.federation.model.SAMLv2Model in project OpenAM by OpenRock.
the class SAMLv2AttrQueryViewBean method handleButton1Request.
public void handleButton1Request(RequestInvocationEvent event) throws ModelControlException {
try {
SAMLv2Model model = (SAMLv2Model) getModel();
AMPropertySheet ps = (AMPropertySheet) getChild(PROPERTY_ATTRIBUTES);
//retrieve the standard metadata values from the property sheet
Map attrQueryValues = ps.getAttributeValues(model.getStandardAttrQueryAttributes(realm, entityName), false, model);
//save the standard metadata values for attribute authority
model.setStdAttributeQueryValues(realm, entityName, attrQueryValues);
//retrieve the extended metadata values from the property sheet
Map attrQueryExtValues = ps.getAttributeValues(model.getattrQueryEXDataMap(), false, model);
//save the extended metadata values for attribute authority
model.setExtAttributeQueryValues(realm, entityName, attrQueryExtValues, location);
setInlineAlertMessage(CCAlert.TYPE_INFO, "message.information", "samlv2.attrquery.property.updated");
} catch (AMConsoleException e) {
setInlineAlertMessage(CCAlert.TYPE_ERROR, "message.error", e.getMessage());
}
forwardTo();
}
Aggregations