+ ini=reinterpret_cast<shibtarget::ShibINI*>(context);
+ if (ini)
+ {
+ ShibINI::Iterator* i=ini->tag_iterator("attributes");
+ for (const string* attrname=i->begin(); attrname; attrname=i->next())
+ {
+ const string& factory=ini->get("attributes",*attrname);
+ if (factory=="scoped")
+ {
+ auto_ptr<XMLCh> temp(XMLString::transcode(attrname->c_str()));
+ SAMLAttribute::regFactory(
+ temp.get(),shibboleth::Constants::SHIB_ATTRIBUTE_NAMESPACE_URI,
+ &ScopedFactory);
+ }
+ else if (factory=="simple")
+ {
+ auto_ptr<XMLCh> temp(XMLString::transcode(attrname->c_str()));
+ SAMLAttribute::regFactory(
+ temp.get(),shibboleth::Constants::SHIB_ATTRIBUTE_NAMESPACE_URI,
+ &SimpleFactory);
+ }
+ }
+ }
+