supported via the "urn:mace:shibboleth:sp:1.3:Logout" Binding value.
-->
<md:SingleLogoutService Location="/Logout" Binding="urn:mace:shibboleth:sp:1.3:Logout"/>
+
+ <!--
+ Some internal debugging support (invoke with a query string "cmd" parameter).
+ By default, access to log or config information is blocked, but a user can
+ echo their own session data.
+ -->
+ <DiagnosticService Location="/Diag" Binding="urn:mace:shibboleth:sp:1.3:Diagnostics"
+ echo="true" log="false" config="false"/>
</Sessions>
</Credentials>
</CredentialsProvider>
+ <!-- Specialized attribute handling for cases with complex syntax. -->
+ <AttributeFactory AttributeName="urn:oid:1.3.6.1.4.1.5923.1.1.1.10"
+ type="edu.internet2.middleware.shibboleth.common.provider.TargetedIDFactory"/>
+
</SPConfig>
chLatin_C, chLatin_o, chLatin_n, chLatin_t, chLatin_r, chLatin_o, chLatin_l, chNull
};
+const XMLCh XML::Literals::acl[] =
+{ chLatin_a, chLatin_c, chLatin_l, chNull };
+
const XMLCh XML::Literals::applicationId[] =
{ chLatin_a, chLatin_p, chLatin_p, chLatin_l, chLatin_i, chLatin_c, chLatin_a, chLatin_t, chLatin_i, chLatin_o, chLatin_n,
chLatin_I, chLatin_d, chNull
chLatin_S, chLatin_e, chLatin_r, chLatin_v, chLatin_i, chLatin_c, chLatin_e, chNull
};
+const XMLCh XML::Literals::AttributeFactory[] =
+{ chLatin_A, chLatin_t, chLatin_t, chLatin_r, chLatin_i, chLatin_b, chLatin_u, chLatin_t, chLatin_e,
+ chLatin_F, chLatin_a, chLatin_c, chLatin_t, chLatin_o, chLatin_r, chLatin_y, chNull
+};
+
+const XMLCh XML::Literals::config[] =
+{ chLatin_c, chLatin_o, chLatin_n, chLatin_f, chLatin_i, chLatin_g, chNull };
+
const XMLCh XML::Literals::CredentialsProvider[] =
{ chLatin_C, chLatin_r, chLatin_e, chLatin_d, chLatin_e, chLatin_n, chLatin_t, chLatin_i, chLatin_a, chLatin_l, chLatin_s,
chLatin_P, chLatin_r, chLatin_o, chLatin_v, chLatin_i, chLatin_d, chLatin_e, chLatin_r, chNull
chLatin_U, chLatin_s, chLatin_e, chNull
};
+const XMLCh XML::Literals::DiagnosticService[] =
+{ chLatin_D, chLatin_i, chLatin_a, chLatin_g, chLatin_n, chLatin_o, chLatin_s, chLatin_t, chLatin_i, chLatin_c,
+ chLatin_S, chLatin_e, chLatin_r, chLatin_v, chLatin_i, chLatin_c, chLatin_e, chNull
+};
+
+const XMLCh XML::Literals::echo[] =
+{ chLatin_e, chLatin_c, chLatin_h, chLatin_o, chNull };
+
const XMLCh XML::Literals::Extensions[] =
{ chLatin_E, chLatin_x, chLatin_t, chLatin_e, chLatin_n, chLatin_s, chLatin_i, chLatin_o, chLatin_n, chLatin_s, chNull };
const XMLCh XML::Literals::Local[] =
{ chLatin_L, chLatin_o, chLatin_c, chLatin_a, chLatin_l, chNull };
+const XMLCh XML::Literals::log[] =
+{ chLatin_l, chLatin_o, chLatin_g, chNull };
+
const XMLCh XML::Literals::logger[] =
{ chLatin_l, chLatin_o, chLatin_g, chLatin_g, chLatin_e, chLatin_r, chNull };
IRequestMapper* m_requestMapper;
map<string,IApplication*> m_appmap;
vector<ICredentials*> m_creds;
+ vector<IAttributeFactory*> m_attrFactories;
// Provides filter to exclude special config elements.
short acceptNode(const DOMNode* node) const;
if (!XMLString::compareString(name,SHIBT_L(Application)) ||
!XMLString::compareString(name,SHIBT_L(AssertionConsumerService)) ||
!XMLString::compareString(name,SHIBT_L(SingleLogoutService)) ||
+ !XMLString::compareString(name,SHIBT_L(DiagnosticService)) ||
!XMLString::compareString(name,SHIBT_L(SessionInitiator)) ||
!XMLString::compareString(name,SHIBT_L(AAPProvider)) ||
!XMLString::compareString(name,SHIBT_L(CredentialUse)) ||
return FILTER_ACCEPT;
const XMLCh* name=node->getLocalName();
if (!XMLString::compareString(name,SHIBT_L(Applications)) ||
+ !XMLString::compareString(name,SHIBT_L(AttributeFactory)) ||
!XMLString::compareString(name,SHIBT_L(CredentialsProvider)) ||
!XMLString::compareString(name,SHIBT_L(Extensions)) ||
!XMLString::compareString(name,SHIBT_L(Implementation)) ||
}
}
+ // Now we load any attribute factories
+ nlist=ReloadableXMLFileImpl::m_root->getElementsByTagNameNS(shibtarget::XML::SHIBTARGET_NS,SHIBT_L(AttributeFactory));
+ for (int i=0; nlist && i<nlist->getLength(); i++) {
+ auto_ptr_char type(static_cast<DOMElement*>(nlist->item(i))->getAttributeNS(NULL,SHIBT_L(type)));
+ log.info("building Attribute factory of type %s...",type.get());
+ IPlugIn* plugin=shibConf.getPlugMgr().newPlugin(type.get(),static_cast<DOMElement*>(nlist->item(i)));
+ if (plugin) {
+ IAttributeFactory* fact=dynamic_cast<IAttributeFactory*>(plugin);
+ if (fact) {
+ m_attrFactories.push_back(fact);
+ ShibConfig::getConfig().regAttributeMapping(
+ static_cast<DOMElement*>(nlist->item(i))->getAttributeNS(NULL,L(AttributeName)),
+ fact
+ );
+ }
+ else {
+ delete plugin;
+ log.fatal("plugin was not an Attribute factory");
+ throw UnsupportedExtensionException("plugin was not an Attribute factory");
+ }
+ }
+ }
+
// Load the default application. This actually has a fixed ID of "default". ;-)
const DOMElement* app=saml::XML::getFirstChildElement(
ReloadableXMLFileImpl::m_root,shibtarget::XML::SHIBTARGET_NS,SHIBT_L(Applications)
// Load any overrides.
nlist=app->getElementsByTagNameNS(shibtarget::XML::SHIBTARGET_NS,SHIBT_L(Application));
- for (int i=0; nlist && i<nlist->getLength(); i++) {
- XMLApplication* iapp=new XMLApplication(m_outer,m_creds,static_cast<DOMElement*>(nlist->item(i)),defapp);
+ for (int j=0; nlist && i<nlist->getLength(); j++) {
+ XMLApplication* iapp=new XMLApplication(m_outer,m_creds,static_cast<DOMElement*>(nlist->item(j)),defapp);
if (m_appmap.find(iapp->getId())!=m_appmap.end()) {
log.fatal("found conf:Application element with duplicate Id attribute");
throw ConfigurationException("found conf:Application element with duplicate Id attribute");
delete i->second;
for (vector<ICredentials*>::iterator j=m_creds.begin(); j!=m_creds.end(); j++)
delete (*j);
+ ShibConfig::getConfig().clearAttributeMappings();
+ for (vector<IAttributeFactory*>::iterator k=m_attrFactories.begin(); k!=m_attrFactories.end(); k++)
+ delete (*k);
}
static const XMLCh address[] = { chLatin_a, chLatin_d, chLatin_d, chLatin_r, chLatin_e, chLatin_s, chLatin_s, chNull };
static const XMLCh port[] = { chLatin_p, chLatin_o, chLatin_r, chLatin_t, chNull };
-static const XMLCh acl[] = { chLatin_a, chLatin_c, chLatin_l, chNull };
class TCPListener : public IListener
{
m_port=12345;
}
- tag=e->getAttributeNS(NULL,acl);
+ tag=e->getAttributeNS(NULL,SHIBT_L(acl));
if (tag && *tag) {
auto_ptr_char temp(tag);
string sockacl=temp.get();
static const XMLCh AAPProvider[];
static const XMLCh AccessControl[];
static const XMLCh AccessControlProvider[];
+ static const XMLCh acl[];
static const XMLCh AND[];
static const XMLCh applicationId[];
static const XMLCh Application[];
static const XMLCh Applications[];
static const XMLCh AssertionConsumerService[];
+ static const XMLCh AttributeFactory[];
+ static const XMLCh config[];
static const XMLCh CredentialsProvider[];
static const XMLCh CredentialUse[];
+ static const XMLCh DiagnosticService[];
+ static const XMLCh echo[];
static const XMLCh Extensions[];
static const XMLCh fatal[];
static const XMLCh FederationProvider[];
static const XMLCh Library[];
static const XMLCh Listener[];
static const XMLCh Local[];
+ static const XMLCh log[];
static const XMLCh logger[];
static const XMLCh MemorySessionCache[];
static const XMLCh MetadataProvider[];