From: Scott Cantor Date: Wed, 30 Jan 2008 17:32:12 +0000 (+0000) Subject: Support path resolution in binding templates. X-Git-Tag: 2.0.0~13 X-Git-Url: http://www.project-moonshot.org/gitweb/?p=shibboleth%2Fcpp-opensaml.git;a=commitdiff_plain;h=b5b26ae562b0317264119a51aa9de40674af1dea Support path resolution in binding templates. --- diff --git a/saml/saml1/binding/impl/SAML1POSTEncoder.cpp b/saml/saml1/binding/impl/SAML1POSTEncoder.cpp index f7c8ecd..2b0107b 100644 --- a/saml/saml1/binding/impl/SAML1POSTEncoder.cpp +++ b/saml/saml1/binding/impl/SAML1POSTEncoder.cpp @@ -31,6 +31,7 @@ #include #include #include +#include #include using namespace opensaml::saml1p; @@ -84,6 +85,7 @@ SAML1POSTEncoder::SAML1POSTEncoder(const DOMElement* e, const XMLCh* ns) } if (m_template.empty()) throw XMLToolingException("SAML1POSTEncoder requires template XML attribute."); + XMLToolingConfig::getConfig().getPathResolver()->resolve(m_template, PathResolver::XMLTOOLING_CFG_FILE); } long SAML1POSTEncoder::encode( diff --git a/saml/saml2/binding/impl/SAML2ArtifactEncoder.cpp b/saml/saml2/binding/impl/SAML2ArtifactEncoder.cpp index f0f590c..a4dd248 100644 --- a/saml/saml2/binding/impl/SAML2ArtifactEncoder.cpp +++ b/saml/saml2/binding/impl/SAML2ArtifactEncoder.cpp @@ -33,6 +33,7 @@ #include #include #include +#include #include #include @@ -86,8 +87,10 @@ SAML2ArtifactEncoder::SAML2ArtifactEncoder(const DOMElement* e, const XMLCh* ns) m_post = (flag && (*flag==chLatin_t || *flag==chDigit_1)); if (m_post) { auto_ptr_char t(e->getAttributeNS(ns, _template)); - if (t.get() && *t.get()) + if (t.get() && *t.get()) { m_template = t.get(); + XMLToolingConfig::getConfig().getPathResolver()->resolve(m_template, PathResolver::XMLTOOLING_CFG_FILE); + } } } } diff --git a/saml/saml2/binding/impl/SAML2POSTEncoder.cpp b/saml/saml2/binding/impl/SAML2POSTEncoder.cpp index 3b303fc..8f122e0 100644 --- a/saml/saml2/binding/impl/SAML2POSTEncoder.cpp +++ b/saml/saml2/binding/impl/SAML2POSTEncoder.cpp @@ -31,6 +31,7 @@ #include #include #include +#include #include using namespace opensaml::saml2p; @@ -89,6 +90,7 @@ SAML2POSTEncoder::SAML2POSTEncoder(const DOMElement* e, const XMLCh* ns, bool si } if (m_template.empty()) throw XMLToolingException("SAML2POSTEncoder requires template XML attribute."); + XMLToolingConfig::getConfig().getPathResolver()->resolve(m_template, PathResolver::XMLTOOLING_CFG_FILE); } long SAML2POSTEncoder::encode(