X-Git-Url: http://www.project-moonshot.org/gitweb/?a=blobdiff_plain;f=saml%2Fbinding%2FSOAPClient.h;h=433e44adc47dfab8bfdacf7cc7ba3d54ed8e5314;hb=6056cca67278d65c4343928e4ceaebd1d6f04920;hp=2c745cc96a16ab4a9ca4dc02999cb63a09b640ed;hpb=b4448d5b2445f818263b600651e67630ff114f22;p=shibboleth%2Fcpp-opensaml.git diff --git a/saml/binding/SOAPClient.h b/saml/binding/SOAPClient.h index 2c745cc..433e44a 100644 --- a/saml/binding/SOAPClient.h +++ b/saml/binding/SOAPClient.h @@ -40,12 +40,10 @@ namespace opensaml { * @param policy reference to SecurityPolicy to apply * @param validating controls schema validation */ - SOAPClient(SecurityPolicy& policy, bool validating=false) - : soap11::SOAPClient(validating), m_policy(policy), m_force(true), m_correlate(NULL) {} + SOAPClient(SecurityPolicy& policy) + : soap11::SOAPClient(policy.getValidating()), m_policy(policy), m_force(true), m_peer(NULL) {} - virtual ~SOAPClient() { - XMLString::release(&m_correlate); - } + virtual ~SOAPClient() {} /** * Controls whether to force transport/peer authentication via an X509TrustEngine. @@ -77,6 +75,15 @@ namespace opensaml { void reset(); + /** + * Returns the SecurityPolicy supplied to the client. + * + * @return the associated SecurityPolicy + */ + SecurityPolicy& getPolicy() const { + return m_policy; + } + protected: /** * Override prepares transport by assigning an X509TrustEngine to it, if one is @@ -84,7 +91,7 @@ namespace opensaml { * * @param transport reference to transport layer */ - void prepareTransport(const xmltooling::SOAPTransport& transport); + void prepareTransport(xmltooling::SOAPTransport& transport); /** Reference to security policy to apply. */ SecurityPolicy& m_policy; @@ -92,10 +99,7 @@ namespace opensaml { /** Flag controlling whether transport/peer authn is mandatory. */ bool m_force; - /** Message correlation ID. */ - XMLCh* m_correlate; - - private: + /** Metadata-based peer identity. */ const saml2md::RoleDescriptor* m_peer; };