/**
* @file shibsp/attribute/resolver/AttributeResolver.h
*
- * The service that resolves the attributes for a particular subject.
+ * A service that transforms or resolves additional attributes for a particular subject.
*/
#ifndef __shibsp_resolver_h__
* Attributes can be supplied while creating the session.
*
* @param application reference to Application that owns the eventual Session
- * @param client_addr network address of client
* @param issuer issuing metadata of assertion issuer, if known
+ * @param protocol protocol used to establish Session
* @param nameid principal identifier, normalized to SAML 2, if any
- * @param tokens assertions initiating the session, if any
+ * @param authncontext_class method/category of authentication event, if known
+ * @param authncontext_decl specifics of authentication event, if known
+ * @param tokens assertions initiating the Session, if any
+ * @param attributes array of previously resolved attributes, if any
* @return newly created ResolutionContext, owned by caller
*/
virtual ResolutionContext* createResolutionContext(
const Application& application,
- const char* client_addr,
const opensaml::saml2md::EntityDescriptor* issuer,
- const opensaml::saml2::NameID* nameid,
- const std::vector<const opensaml::Assertion*>* tokens=NULL
+ const XMLCh* protocol,
+ const opensaml::saml2::NameID* nameid=NULL,
+ const XMLCh* authncontext_class=NULL,
+ const XMLCh* authncontext_decl=NULL,
+ const std::vector<const opensaml::Assertion*>* tokens=NULL,
+ const std::vector<Attribute*>* attributes=NULL
) const=0;
/**
/**
- * Gets the attributes for a given subject and returns them in the supplied context.
+ * Resolves attributes for a given subject and returns them in the supplied context.
*
* @param ctx resolution context to use to resolve attributes
- * @param attributes set of attributes to resolve or NULL to resolve all attributes
*
* @throws AttributeResolutionException thrown if there is a problem resolving the attributes for the subject
*/
- virtual void resolveAttributes(ResolutionContext& ctx, const std::set<std::string>* attributes=NULL) const=0;
+ virtual void resolveAttributes(ResolutionContext& ctx) const=0;
+
+ /**
+ * Populates an array with the set of Attribute IDs that might be generated.
+ *
+ * @param attributes array to populate
+ */
+ virtual void getAttributeIds(std::vector<std::string>& attributes) const=0;
};
#if defined (_MSC_VER)
*/
void SHIBSP_API registerAttributeResolvers();
- /** AttributeResolver based on a simple mapping of SAML information. */
- #define SIMPLE_ATTRIBUTE_RESOLVER "Simple"
+ /** AttributeResolver based on SAML queries to an IdP during SSO. */
+ #define QUERY_ATTRIBUTE_RESOLVER "Query"
+
+ /** AttributeResolver based on chaining together other resolvers. */
+ #define CHAINING_ATTRIBUTE_RESOLVER "Chaining"
};
#endif /* __shibsp_resolver_h__ */