Major revamp of credential and trust handling code, PKIX engine still needs work.
[shibboleth/cpp-opensaml.git] / samltest / saml1 / binding / SAML1POSTTest.h
index c6284df..eb8278c 100644 (file)
@@ -46,6 +46,12 @@ public:
                 );
             janitor.release();
 
+            CredentialCriteria cc;\r
+            cc.setUsage(CredentialCriteria::SIGNING_CREDENTIAL);\r
+            Locker clocker(m_creds);\r
+            const Credential* cred = m_creds->resolve(&cc);\r
+            TSM_ASSERT("Retrieved credential was null", cred!=NULL);\r
+
             // Freshen timestamp and ID.
             toSend->setIssueInstant(time(NULL));
             toSend->setResponseID(NULL);
@@ -64,7 +70,7 @@ public:
                     samlconstants::SAML1_PROFILE_BROWSER_POST, encoder_config->getDocumentElement()
                     )
                 );
-            encoder->encode(*this,toSend.get(),"https://sp.example.org/SAML/SSO","https://sp.example.org/","state",m_creds);
+            encoder->encode(*this,toSend.get(),"https://sp.example.org/SAML/SSO","https://sp.example.org/","state",cred);
             toSend.release();
             
             // Decode message.