You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2013/03/14 17:24:40 UTC
svn commit: r1456507 -
/cxf/branches/wss4j2.0-port/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/WSSecurityPolicyLoader.java
Author: dkulp
Date: Thu Mar 14 16:24:39 2013
New Revision: 1456507
URL: http://svn.apache.org/r1456507
Log:
Policies that contain policies or have other attributes cannot use a singleton.
Modified:
cxf/branches/wss4j2.0-port/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/WSSecurityPolicyLoader.java
Modified: cxf/branches/wss4j2.0-port/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/WSSecurityPolicyLoader.java
URL: http://svn.apache.org/viewvc/cxf/branches/wss4j2.0-port/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/WSSecurityPolicyLoader.java?rev=1456507&r1=1456506&r2=1456507&view=diff
==============================================================================
--- cxf/branches/wss4j2.0-port/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/WSSecurityPolicyLoader.java (original)
+++ cxf/branches/wss4j2.0-port/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/WSSecurityPolicyLoader.java Thu Mar 14 16:24:39 2013
@@ -145,6 +145,16 @@ public final class WSSecurityPolicyLoade
reg.registerBuilder(new WSS10Builder());
reg.registerBuilder(new WSS11Builder());
reg.registerBuilder(new X509TokenBuilder());
+
+ //This is for the assertions that would contain nested policies
+ reg.registerBuilder(new XMLPrimitiveAssertionBuilder() {
+ public QName[] getKnownElements() {
+ return new QName[] {
+ //SecureConversation
+ SP12Constants.BOOTSTRAP_POLICY, SP11Constants.BOOTSTRAP_POLICY,
+ };
+ }
+ });
//add generic assertions for these known things to prevent warnings
List<QName> others = Arrays.asList(new QName[] {
@@ -207,11 +217,8 @@ public final class WSSecurityPolicyLoade
// Spnego
SP12Constants.MUST_NOT_SEND_AMEND,
SP12Constants.MUST_NOT_SEND_CANCEL,
- SP12Constants.MUST_NOT_SEND_RENEW,
+ SP12Constants.MUST_NOT_SEND_RENEW,
- // SecureConversation
- SP12Constants.BOOTSTRAP_POLICY,
- SP11Constants.BOOTSTRAP_POLICY,
// Backwards compatibility thing
new QName("http://schemas.microsoft.com/ws/2005/07/securitypolicy", "MustNotSendCancel"),