use of org.apache.wss4j.policy.model.Trust13 in project cxf by apache.
the class AbstractCommonBindingHandler method assertTrustProperties.
protected void assertTrustProperties(String namespace) {
AssertionInfoMap aim = message.get(AssertionInfoMap.class);
Collection<AssertionInfo> trust10Ais = aim.get(new QName(namespace, SPConstants.TRUST_10));
if (trust10Ais != null) {
for (AssertionInfo ai : trust10Ais) {
ai.setAsserted(true);
Trust10 trust10 = (Trust10) ai.getAssertion();
assertTrust10Properties(trust10);
}
}
Collection<AssertionInfo> trust13Ais = aim.get(new QName(namespace, SPConstants.TRUST_13));
if (trust13Ais != null) {
for (AssertionInfo ai : trust13Ais) {
ai.setAsserted(true);
Trust13 trust13 = (Trust13) ai.getAssertion();
assertTrust10Properties(trust13);
if (trust13.isRequireRequestSecurityTokenCollection()) {
assertPolicy(new QName(namespace, SPConstants.REQUIRE_REQUEST_SECURITY_TOKEN_COLLECTION));
}
if (trust13.isRequireAppliesTo()) {
assertPolicy(new QName(namespace, SPConstants.REQUIRE_APPLIES_TO));
}
if (trust13.isScopePolicy15()) {
assertPolicy(new QName(namespace, SPConstants.SCOPE_POLICY_15));
}
if (trust13.isMustSupportInteractiveChallenge()) {
assertPolicy(new QName(namespace, SPConstants.MUST_SUPPORT_INTERACTIVE_CHALLENGE));
}
}
}
}
Aggregations