From 9758558e9ec6a6a2e052dbea2b82070bc0cd13f2 Mon Sep 17 00:00:00 2001 From: Scott Cantor Date: Mon, 5 Feb 2007 16:11:03 +0000 Subject: [PATCH] Move policy execution above the destination check. --- saml/saml2/binding/impl/SAML2RedirectDecoder.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/saml/saml2/binding/impl/SAML2RedirectDecoder.cpp b/saml/saml2/binding/impl/SAML2RedirectDecoder.cpp index 4c8e3b0..489f709 100644 --- a/saml/saml2/binding/impl/SAML2RedirectDecoder.cpp +++ b/saml/saml2/binding/impl/SAML2RedirectDecoder.cpp @@ -128,6 +128,9 @@ XMLObject* SAML2RedirectDecoder::decode( if (!m_validate) SchemaValidators.validate(xmlObject.get()); + // Run through the policy. + policy.evaluate(*root, &genericRequest); + // Check destination URL. auto_ptr_char dest(request ? request->getDestination() : response->getDestination()); const char* dest2 = httpRequest->getRequestURL(); @@ -140,8 +143,5 @@ XMLObject* SAML2RedirectDecoder::decode( throw BindingException("SAML message delivered with Redirect to incorrect server URL."); } - // Run through the policy. - policy.evaluate(*root, &genericRequest); - return xmlObject.release(); } -- 2.1.4