SAML Signature subclasses and test.
[shibboleth/cpp-opensaml.git] / saml / saml1 / core / impl / AssertionsSchemaValidators.cpp
index 2980972..815d725 100644 (file)
@@ -113,6 +113,8 @@ namespace opensaml {
                 ptr->getSubjectStatements().empty() &&
                 ptr->getStatements().empty())
                 throw ValidationException("Assertion must have at least one statement.");
+            if (ptr->getMinorVersion()==0 && ptr->getConditions() && !ptr->getConditions()->getDoNotCacheConditions().empty())
+                throw ValidationException("SAML 1.0 assertions cannot contain DoNotCacheCondition elements.");
         END_XMLOBJECTVALIDATOR;
 
         class SAML_DLLLOCAL checkWildcardNS {