protected void validateDoNotCache(Assertion assertion) throws ValidationException { if (assertion.getMinorVersion() == 0) { Conditions conditions = assertion.getConditions(); if (conditions != null) { for (Condition condition : conditions.getConditions()) { if (condition instanceof DoNotCacheCondition) { throw new ValidationException("DoNotCacheCondition not valid in SAML1.0"); } } } } } }
@Override protected void processSAMLAssertion() { this.setAssertionId(assertion.getID()); //Read the validity period from the 'Conditions' element, else read it from SC Data if (assertion.getConditions() != null) { Conditions conditions = assertion.getConditions(); if (conditions.getNotBefore() != null) { this.setDateNotBefore(conditions.getNotBefore().toDate()); } if (conditions.getNotOnOrAfter() != null) { this.setDateNotOnOrAfter(conditions.getNotOnOrAfter().toDate()); } } }
validTill = assertion.getSaml2().getConditions().getNotOnOrAfter(); } else if (assertion.getSamlVersion().equals(SAMLVersion.VERSION_11) && assertion.getSaml1().getConditions() != null) { validFrom = assertion.getSaml1().getConditions().getNotBefore(); validTill = assertion.getSaml1().getConditions().getNotOnOrAfter();
issueInstant = assertion.getSaml2().getIssueInstant(); } else if (assertion.getSamlVersion().equals(SAMLVersion.VERSION_11) && assertion.getSaml1().getConditions() != null) { validFrom = assertion.getSaml1().getConditions().getNotBefore(); validTill = assertion.getSaml1().getConditions().getNotOnOrAfter(); issueInstant = assertion.getSaml1().getIssueInstant();
issueInstant = assertion.getSaml2().getIssueInstant(); } else if (assertion.getSamlVersion().equals(SAMLVersion.VERSION_11) && assertion.getSaml1().getConditions() != null) { validFrom = assertion.getSaml1().getConditions().getNotBefore(); validTill = assertion.getSaml1().getConditions().getNotOnOrAfter(); issueInstant = assertion.getSaml1().getIssueInstant();
Conditions conditions = assertion.getConditions(); if (conditions != null) { List<AudienceRestrictionCondition> audienceRestrictions = conditions.getAudienceRestrictionConditions(); boolean bearerFound = false; if (assertion.getConditions() != null && assertion.getConditions().getNotOnOrAfter() != null) { notOnOrAfterFromConditions = assertion.getConditions().getNotOnOrAfter();
Conditions conditions = assertion.getConditions(); if (conditions != null) { List<AudienceRestrictionCondition> audienceRestrictions = conditions.getAudienceRestrictionConditions(); boolean bearerFound = false; if (assertion.getConditions() != null && assertion.getConditions().getNotOnOrAfter() != null) { notOnOrAfterFromConditions = assertion.getConditions().getNotOnOrAfter();
&& assertion.getSaml1().getConditions() != null) { org.opensaml.saml1.core.Conditions conditions = assertion.getSaml1().getConditions(); if (conditions != null && conditions.getAudienceRestrictionConditions() != null && !conditions.getAudienceRestrictionConditions().isEmpty()) {
&& assertion.getSaml1().getConditions() != null) { org.opensaml.saml1.core.Conditions conditions = assertion.getSaml1().getConditions(); if (conditions != null && conditions.getAudienceRestrictionConditions() != null && !conditions.getAudienceRestrictionConditions().isEmpty()) {
if (samlAssertion.getConditions() == null) { samlAssertion.setConditions((Conditions) CommonUtil.buildXMLObject(Conditions.DEFAULT_ELEMENT_NAME)); samlAssertion.getConditions().setNotBefore(new DateTime(creationTime)); samlAssertion.getConditions().setNotOnOrAfter(new DateTime(expirationTime));