You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ws.apache.org by co...@apache.org on 2016/02/18 10:07:24 UTC

svn commit: r1731025 - in /webservices/wss4j/branches/2_1_x-fixes: ws-security-common/src/main/java/org/apache/wss4j/common/WSS4JConstants.java ws-security-dom/src/main/java/org/apache/wss4j/dom/util/WSSecurityUtil.java

Author: coheigea
Date: Thu Feb 18 09:07:23 2016
New Revision: 1731025

URL: http://svn.apache.org/viewvc?rev=1731025&view=rev
Log:
[WSS-567] - processSecurityHeadaers does not work for 1.1 namespace

Modified:
    webservices/wss4j/branches/2_1_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/WSS4JConstants.java
    webservices/wss4j/branches/2_1_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/util/WSSecurityUtil.java

Modified: webservices/wss4j/branches/2_1_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/WSS4JConstants.java
URL: http://svn.apache.org/viewvc/webservices/wss4j/branches/2_1_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/WSS4JConstants.java?rev=1731025&r1=1731024&r2=1731025&view=diff
==============================================================================
--- webservices/wss4j/branches/2_1_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/WSS4JConstants.java (original)
+++ webservices/wss4j/branches/2_1_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/WSS4JConstants.java Thu Feb 18 09:07:23 2016
@@ -33,6 +33,8 @@ public class WSS4JConstants {
         "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd";
     public static final String WSSE11_NS =
         "http://docs.oasis-open.org/wss/oasis-wss-wssecurity-secext-1.1.xsd";
+    public static final String OLD_WSSE_NS =
+        "http://schemas.xmlsoap.org/ws/2002/04/secext";
     public static final String WSU_NS =
         "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";
 

Modified: webservices/wss4j/branches/2_1_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/util/WSSecurityUtil.java
URL: http://svn.apache.org/viewvc/webservices/wss4j/branches/2_1_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/util/WSSecurityUtil.java?rev=1731025&r1=1731024&r2=1731025&view=diff
==============================================================================
--- webservices/wss4j/branches/2_1_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/util/WSSecurityUtil.java (original)
+++ webservices/wss4j/branches/2_1_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/util/WSSecurityUtil.java Thu Feb 18 09:07:23 2016
@@ -120,7 +120,8 @@ public final class WSSecurityUtil {
         ) {
             if (Node.ELEMENT_NODE == currentChild.getNodeType()
                 && WSConstants.WSSE_LN.equals(currentChild.getLocalName())
-                && WSConstants.WSSE_NS.equals(currentChild.getNamespaceURI())) {
+                && (WSConstants.WSSE_NS.equals(currentChild.getNamespaceURI())
+                    || WSConstants.OLD_WSSE_NS.equals(currentChild.getNamespaceURI()))) {
 
                 Element elem = (Element)currentChild;
                 Attr attr = elem.getAttributeNodeNS(soapNamespace, actorLocal);