Log decrypted objects.
authorcantor <cantor@cb58f699-b61c-0410-a6fe-9272a202ed29>
Tue, 8 Jan 2008 19:34:32 +0000 (19:34 +0000)
committercantor <cantor@cb58f699-b61c-0410-a6fe-9272a202ed29>
Tue, 8 Jan 2008 19:34:32 +0000 (19:34 +0000)
git-svn-id: https://svn.middleware.georgetown.edu/cpp-sp/trunk@2685 cb58f699-b61c-0410-a6fe-9272a202ed29

shibsp/attribute/resolver/impl/XMLAttributeExtractor.cpp
shibsp/handler/impl/SAML2Consumer.cpp

index 6ad8584..972a41f 100644 (file)
@@ -495,10 +495,14 @@ void XMLExtractor::extractAttributes(
                 if (issuer) {
                     MetadataCredentialCriteria mcc(*issuer);
                     auto_ptr<XMLObject> decrypted(encattr->decrypt(*cr, recipient, &mcc));
+                    if (m_log.isDebugEnabled())
+                        m_log.debugStream() << "decrypted Attribute:" << logging::eol << *(decrypted.get()) << logging::eol;
                     return extractAttributes(application, issuer, *(decrypted.get()), attributes);
                 }
                 else {
                     auto_ptr<XMLObject> decrypted(encattr->decrypt(*cr, recipient));
+                    if (m_log.isDebugEnabled())
+                        m_log.debugStream() << "decrypted Attribute:" << logging::eol << *(decrypted.get()) << logging::eol;
                     return extractAttributes(application, issuer, *(decrypted.get()), attributes);
                 }
             }
index cc2118c..0b5a416 100644 (file)
@@ -229,6 +229,8 @@ void SAML2Consumer::implementProtocol(
             if (decrypted) {
                 wrapper.release();
                 ownedtokens.push_back(decrypted);
+                if (m_log.isDebugEnabled())
+                    m_log.debugStream() << "decrypted Assertion:" << logging::eol << *decrypted << logging::eol;
             }
         }
         catch (exception& ex) {
@@ -316,6 +318,8 @@ void SAML2Consumer::implementProtocol(
                     if (ssoName) {
                         ownedName = true;
                         decryptedID.release();
+                        if (m_log.isDebugEnabled())
+                            m_log.debugStream() << "decrypted NameID:" << logging::eol << *ssoName << logging::eol;
                     }
                 }
                 catch (exception& ex) {